Python client for URLR
Project description
urlr@2.11.0
This SDK is automatically generated with the OpenAPI Generator project.
- API version: 1.10
- Package version: 2.11.0
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
For more information, please visit https://urlr.me/en
Installation & Usage
Requirements
Python 3.9+
pip install
pip install urlr
Then import the package:
import urlr
Setuptools
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 urlr
Tests
Execute pytest to run the tests.
Getting Started
Please follow the installation procedure and then run the following:
import urlr
from urlr.rest import ApiException
from pprint import pprint
# Access Tokens
with urlr.ApiClient() as api_client:
access_tokens_api = urlr.AccessTokensApi(api_client)
access_tokens_request = urlr.AccessTokensRequest.from_json('{"username": "","password": ""}')
try:
api_response = access_tokens_api.create_access_token(access_tokens_request=access_tokens_request)
except ApiException as e:
print("Exception when calling AccessTokensApi->create_access_token: %s\n" % e)
quit()
# Link shortening
configuration = urlr.Configuration(
access_token = api_response.token
)
with urlr.ApiClient(configuration) as api_client:
link_api = urlr.LinksApi(api_client)
create_link_request = urlr.CreateLinkRequest.from_json('{"url": "","team_id": ""}')
try:
# Create a link
api_response = link_api.create_link(create_link_request=create_link_request)
print(api_response)
except Exception as e:
print("Exception when calling LinksApi->create_link: %s\n" % e)
A complete example is available here.
API Endpoints
All URIs are relative to https://urlr.me/api/v1
| Class | Method | HTTP request | Description |
|---|---|---|---|
| AccessTokensApi | create_access_token | POST /access_tokens/create | Get an access token |
| AccessTokensApi | refresh_access_token | POST /access_tokens/refresh | Refresh an access token |
| DomainsApi | create_domain | POST /domains/create | Create a domain |
| FoldersApi | get_folders | GET /folders/{team_id} | Get folders of workspace |
| LinksApi | create_link | POST /links/create | Create a link |
| LinksApi | edit_link | PATCH /links/{link_id} | Edit a link |
| LinksApi | get_link | GET /links/{link_id} | Get a link |
| QRCodesApi | create_qr_code | POST /qrcodes/create | Create a QR Code |
| StatisticsApi | get_statistics | POST /statistics | Get statistics of a link |
| WorkspacesApi | get_teams | GET /teams | Get workspaces of user |
Models
- BaseLinkRequest
- BaseLinkRequestMetatag
- BaseLinkRequestQrcode
- CreateAccessToken200Response
- CreateAccessToken401Response
- CreateAccessTokenRequest
- CreateDomain200Response
- CreateDomain409Response
- CreateDomainRequest
- CreateLink429Response
- CreateLinkRequest
- CreateQrCodeRequest
- CreateQrCodeRequestOneOf
- CreateQrCodeRequestOneOf1
- EditLink500Response
- EditLinkRequest
- GetFolders200Response
- GetFolders200ResponseFoldersInner
- GetLink200Response
- GetLink200ResponseGeolinksInner
- GetLink200ResponseGeolinksInnerConditionsInner
- GetLink200ResponseMetatag
- GetLink200ResponseQrcode
- GetLink200ResponseTagsInner
- GetLink200ResponseUtm
- GetLink401Response
- GetLink404Response
- GetLink422Response
- GetStatistics200Response
- GetStatisticsRequest
- GetTeams200Response
- GetTeams200ResponseTeamsInner
- RefreshAccessToken401Response
- RefreshAccessTokenRequest
Authorization
Authentication schemes defined for the API:
bearerAuth
- Type: Bearer authentication (JWT)
Get help / support
Please contact contact@urlr.me and we can take more direct action toward finding a solution.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file urlr-2.11.0.tar.gz.
File metadata
- Download URL: urlr-2.11.0.tar.gz
- Upload date:
- Size: 41.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
99ec4ed4fe3a4de169e162d64876b342598385538bb9a4e070a3dab098edcafe
|
|
| MD5 |
b88a6ec36f04e5c00fbef9a1fe49f890
|
|
| BLAKE2b-256 |
b2ea9e7fbf4dc442e1fe761f737497c1e36dd96354fc861e4a410105c239ccea
|
File details
Details for the file urlr-2.11.0-py3-none-any.whl.
File metadata
- Download URL: urlr-2.11.0-py3-none-any.whl
- Upload date:
- Size: 93.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
980c1167a24032786ebe19890feb9ffe92359c4c17da36b09d58f8a604e2ae57
|
|
| MD5 |
09035bc6c10e29236a2bc9c846443cbb
|
|
| BLAKE2b-256 |
900eab21f132f172b623cc4548c0a4a16f61eb68076d1335b70ebb44d261eef7
|