https://github.com/kit-data-manager/typid-client
https://github.com/kit-data-manager/typid-client
Last synced: 9 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/kit-data-manager/typid-client
- Owner: kit-data-manager
- Created: 2025-08-06T15:11:03.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2025-08-08T14:56:34.000Z (10 months ago)
- Last Synced: 2025-08-08T16:36:19.800Z (10 months ago)
- Language: Python
- Size: 157 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# pytypid
> NOTE: This is still experimental. Do not use in production.
This package is an abstration of the Typed PID Maker API, making usage via python simple. It contains an automatically generated (using [openapi-generator](https://openapi-generator.tech/)) abstraction layer in the module `pytypid_generated_client`, and some hand-written, high-level extensions or utilities in `pytypid`.
The Typed PID Maker is a service for creating, updating, obtaining and validating PID record information using Kernel Information Profiles, as defined by the Research Data Alliance.
This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
- API version: 2.0.0
- Package version: 0.2.0
- Generator version: 7.14.0
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
For more information, please visit [https://github.com/kit-data-manager](https://github.com/kit-data-manager)
## Requirements.
Python 3.9+
## Installation & Usage
### pip install
If the python package is hosted on a repository, you can install directly using:
```sh
pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git
```
(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git`)
Then import the package:
```python
import pytypid_generated_client
```
### Setuptools
Install via [Setuptools](http://pypi.python.org/pypi/setuptools).
```sh
python setup.py install --user
```
(or `sudo python setup.py install` to install the package for all users)
Then import the package:
```python
import pytypid_generated_client
```
### Tests
Execute `pytest` to run the tests.
## Getting Started
Please follow the [installation procedure](#installation--usage) and then run the following:
```python
import pytypid_generated_client
from pytypid_generated_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://typed-pid-maker.datamanager.kit.edu/preview
# See configuration.py for a list of all supported configuration parameters.
configuration = pytypid_generated_client.Configuration(
host = "http://typed-pid-maker.datamanager.kit.edu/preview"
)
# Enter a context with an instance of the API client
with pytypid_generated_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pytypid_generated_client.ActuatorApi(api_client)
try:
# Actuator web endpoint 'health'
api_response = api_instance.health()
print("The response of ActuatorApi->health:\n")
pprint(api_response)
except ApiException as e:
print("Exception when calling ActuatorApi->health: %s\n" % e)
```
## Documentation for API Endpoints
All URIs are relative to *http://typed-pid-maker.datamanager.kit.edu/preview*
Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*ActuatorApi* | [**health**](docs/ActuatorApi.md#health) | **GET** /actuator/health | Actuator web endpoint 'health'
*ActuatorApi* | [**info**](docs/ActuatorApi.md#info) | **GET** /actuator/info | Actuator web endpoint 'info'
*ActuatorApi* | [**links**](docs/ActuatorApi.md#links) | **GET** /actuator | Actuator root web endpoint
*PIDManagementApi* | [**create_pid**](docs/PIDManagementApi.md#create_pid) | **POST** /api/v1/pit/pid/ | Create a new PID record
*PIDManagementApi* | [**create_pids**](docs/PIDManagementApi.md#create_pids) | **POST** /api/v1/pit/pids | Create a multiple, possibly related PID records
*PIDManagementApi* | [**find_all**](docs/PIDManagementApi.md#find_all) | **GET** /api/v1/pit/known-pid | Returns all known PIDs. Supports paging, filtering criteria, and different formats.
*PIDManagementApi* | [**find_by_pid**](docs/PIDManagementApi.md#find_by_pid) | **GET** /api/v1/pit/known-pid/** | Returns a PID and its timestamps from the local store, if available.
*PIDManagementApi* | [**get_record**](docs/PIDManagementApi.md#get_record) | **GET** /api/v1/pit/pid/** | Get the record of the given PID.
*PIDManagementApi* | [**update_pid**](docs/PIDManagementApi.md#update_pid) | **PUT** /api/v1/pit/pid/** | Update an existing PID record
## Documentation For Models
- [BatchRecordResponse](docs/BatchRecordResponse.md)
- [FindAll200Response](docs/FindAll200Response.md)
- [KnownPid](docs/KnownPid.md)
- [Link](docs/Link.md)
- [PIDRecord](docs/PIDRecord.md)
- [PIDRecordEntry](docs/PIDRecordEntry.md)
- [SimplePair](docs/SimplePair.md)
- [SimplePidRecord](docs/SimplePidRecord.md)
- [TabulatorPaginationFormat](docs/TabulatorPaginationFormat.md)
- [TabulatorPaginationFormatKnownPid](docs/TabulatorPaginationFormatKnownPid.md)
## Documentation For Authorization
Authentication schemes defined for the API:
### bearer-jwt
- **Type**: Bearer authentication (JWT)
## Author
support@datamanager.kit.edu