Rekor is a cryptographically secure, immutable transparency log for signed software releases.
This Python package is automatically generated by the Swagger Codegen project:
- API version: 1.0.0
- Package version: 1.0.0
- Build package: io.swagger.codegen.v3.generators.python.PythonClientCodegen
Python 2.7 and 3.4+
If the python package is hosted on Github, you can install directly from Github
pip install git+https://github.com/peridotbuild/rekor-python-sdk.git
(you may need to run pip
with root permission: sudo pip install git+https://github.com/peridotbuild/rekor-python-sdk.git
)
Then import the package:
import rekor_sdk
Install via Setuptools.
python setup.py install --user
(or sudo python setup.py install
to install the package for all users)
Then import the package:
import rekor_sdk
Please follow the installation procedure and then run the following:
from __future__ import print_function
import time
import rekor_sdk
from rekor_sdk.rest import ApiException
from pprint import pprint
# create an instance of the API class
api_instance = rekor_sdk.EntriesApi(rekor_sdk.ApiClient(configuration))
body = rekor_sdk.ProposedEntry() # ProposedEntry |
try:
# Creates an entry in the transparency log
api_response = api_instance.create_log_entry(body)
pprint(api_response)
except ApiException as e:
print("Exception when calling EntriesApi->create_log_entry: %s\n" % e)
# create an instance of the API class
api_instance = rekor_sdk.EntriesApi(rekor_sdk.ApiClient(configuration))
log_index = 56 # int | specifies the index of the entry in the transparency log to be retrieved
try:
# Retrieves an entry and inclusion proof from the transparency log (if it exists) by index
api_response = api_instance.get_log_entry_by_index(log_index)
pprint(api_response)
except ApiException as e:
print("Exception when calling EntriesApi->get_log_entry_by_index: %s\n" % e)
# create an instance of the API class
api_instance = rekor_sdk.EntriesApi(rekor_sdk.ApiClient(configuration))
entry_uuid = 'entry_uuid_example' # str | the UUID of the entry for which the inclusion proof information should be returned
try:
# Get log entry and information required to generate an inclusion proof for the entry in the transparency log
api_response = api_instance.get_log_entry_by_uuid(entry_uuid)
pprint(api_response)
except ApiException as e:
print("Exception when calling EntriesApi->get_log_entry_by_uuid: %s\n" % e)
# create an instance of the API class
api_instance = rekor_sdk.EntriesApi(rekor_sdk.ApiClient(configuration))
body = rekor_sdk.SearchLogQuery() # SearchLogQuery |
try:
# Searches transparency log for one or more log entries
api_response = api_instance.search_log_query(body)
pprint(api_response)
except ApiException as e:
print("Exception when calling EntriesApi->search_log_query: %s\n" % e)
All URIs are relative to http://rekor.sigstore.dev/
Class | Method | HTTP request | Description |
---|---|---|---|
EntriesApi | create_log_entry | POST /api/v1/log/entries | Creates an entry in the transparency log |
EntriesApi | get_log_entry_by_index | GET /api/v1/log/entries | Retrieves an entry and inclusion proof from the transparency log (if it exists) by index |
EntriesApi | get_log_entry_by_uuid | GET /api/v1/log/entries/{entryUUID} | Get log entry and information required to generate an inclusion proof for the entry in the transparency log |
EntriesApi | search_log_query | POST /api/v1/log/entries/retrieve | Searches transparency log for one or more log entries |
IndexApi | search_index | POST /api/v1/index/retrieve | Searches index by entry metadata |
PubkeyApi | get_public_key | GET /api/v1/log/publicKey | Retrieve the public key that can be used to validate the signed tree head |
TlogApi | get_log_info | GET /api/v1/log | Get information about the current state of the transparency log |
TlogApi | get_log_proof | GET /api/v1/log/proof | Get information required to generate a consistency proof for the transparency log |
- Alpine
- AlpineSchema
- ConsistencyProof
- Cose
- CoseSchema
- Dsse
- DsseSchema
- Error
- Hashedrekord
- HashedrekordSchema
- Helm
- HelmSchema
- InactiveShardLogInfo
- InclusionProof
- Intoto
- IntotoSchema
- Jar
- JarSchema
- LogEntry
- LogInfo
- ProposedEntry
- Rekord
- RekordSchema
- Rfc3161
- Rfc3161Schema
- Rpm
- RpmSchema
- SearchIndex
- SearchIndexPublicKey
- SearchLogQuery
- Tuf
- TufSchema
All endpoints do not require authorization.