Skip to main content

Secure API Signature Mechanism

Internal used for creating signed url for server installed api-key-server

Install

pip install api-key-client

Example:

  1. sign_request_1(url, api_key, api_secret) recommand
>>> from api_key_client.utils import sign_request_1
>>> url = 'https://api.example.co/sample/something-important/'
>>> sign_request_1(url, 'SOME-TEST', 'some-key-xxxxxx')
'https://api.example.co/sample/something-important/?api_key=SOME-TEST&timestamp=20220209144716&sign=7f210048e1e972d968186f8a35a86f9a'
  1. sign_request_1(url, api_secret)

    place api_key in url

# sign.py
>>> from api_key.utils import sign_request, sign_request_1
>>> url = 'https://example.site.com/sample/secret-info/?api_key=xxx&xxxxx=true&id=163'
>>> url = sign_request(url, 'your_secret')


> Note:

please check system date to the correct timezone,
Otherwise the timeout checking could be invalid

For docker container (alpine)
```dockerfile
RUN apk add --updat tzdata
ENV TZ=Pacific/Auckland

Release files for api-key-client 0.1.10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for api-key-client 0.1.10
File Size Uploaded
api-key-client-0.1.10.tar.gz 2.4 kB Details

Release files / api-key-client-0.1.10.tar.gz

Download URL api-key-client-0.1.10.tar.gz
Size 2.4 kB
Tags Source
SHA-256 checksum
How to use checksums
04d38882a466a85d4e8a41e78b341132a07189fef03dc53635f25f243a648529
BLAKE2b-256 checksum
How to use checksums
d4698637740b11b9a7e6316eda66474c895729e47c80ce40e161e83785ace2a1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.8

Release history Release notifications | RSS feed

This release

0.1.10 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page