authservice


Nameauthservice JSON
Version 0.0.2 PyPI version JSON
download
home_pagehttps://github.com/CodeCrew24/authservice_python
SummaryWith this SDK, Python developers can easily interact with the Auth API, enabling hassle-free implementation of user registration, login, and client credential management features within their applications.
upload_time2024-03-04 05:59:25
maintainer
docs_urlNone
authorCode Crew24
requires_python
licenseMIT
keywords token based auth bearer token auth service
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage No coveralls.
            # authservice
This API provides token-based authentication for user registration, login, and client credential management. It ensures secure communication by utilizing tokens for authentication. Users can register with unique usernames and passwords, authenticate using client credentials, retrieve client IDs and secrets, and regenerate client credentials as needed. The API supports various user roles, including 'user', 'admin', 'moderator', 'guest', and 'superadmin'.

This package is published in PyPI:
```sh
https://pypi.org/project/authservice/
```
## Requirements.

Python 3.7+

## Installation & Usage
### pip install
If your package is hosted in PyPI:
```sh
pip install authservice
```
If the python package is hosted on a repository, you can install directly using:

```sh
pip install git+https://github.com/CodeCrew24/authservice_python
```
(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/CodeCrew24/authservice_python`)

Then import the package:
```python
import authservice
```

### 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 authservice
```

### Tests

Execute `pytest` to run the tests.

## Getting Started

Please follow the [installation procedure](#installation--usage) and then run the following:

```python

import authservice
from authservice.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://auth-service-latest.onrender.com/auth
# See configuration.py for a list of all supported configuration parameters.
configuration = authservice.Configuration(
    host = "https://auth-service-latest.onrender.com/auth"
)



# Enter a context with an instance of the API client
with authservice.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = authservice.DefaultApi(api_client)
    username = 'johndoe' # str | User's username
    password = 'password123' # str | User's password

    try:
        # Get client ID and secret
        api_response = api_instance.client_get(username, password)
        print("The response of DefaultApi->client_get:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling DefaultApi->client_get: %s\n" % e)

```

## Documentation for API Endpoints

All URIs are relative to *https://auth-service-latest.onrender.com/auth*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*DefaultApi* | [**client_get**](docs/DefaultApi.md#client_get) | **GET** /client | Get client ID and secret
*DefaultApi* | [**login_client_post**](docs/DefaultApi.md#login_client_post) | **POST** /login/client | Logs in a user using client ID and secret
*DefaultApi* | [**regenerate_client_credentials_post**](docs/DefaultApi.md#regenerate_client_credentials_post) | **POST** /regenerate-client-credentials | Regenerate client credentials
*DefaultApi* | [**register_post**](docs/DefaultApi.md#register_post) | **POST** /register | Registers a new user


## Documentation For Models

 - [ClientGet200Response](docs/ClientGet200Response.md)
 - [ClientGet401Response](docs/ClientGet401Response.md)
 - [LoginClientPost200Response](docs/LoginClientPost200Response.md)
 - [LoginClientPost401Response](docs/LoginClientPost401Response.md)
 - [RegenerateClientCredentialsPost200Response](docs/RegenerateClientCredentialsPost200Response.md)
 - [RegisterPost201Response](docs/RegisterPost201Response.md)
 - [RegisterPost400Response](docs/RegisterPost400Response.md)
 - [RegisterPost500Response](docs/RegisterPost500Response.md)


<a id="documentation-for-authorization"></a>
## Documentation For Authorization

Endpoints do not require authorization.


## Author





            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/CodeCrew24/authservice_python",
    "name": "authservice",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "token based auth,Bearer Token,Auth Service",
    "author": "Code Crew24",
    "author_email": "dprakash2101@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/98/be/b04b6b7872244e96af56aaca3ea936e317be33064841a8eaad6b0d2dcb7a/authservice-0.0.2.tar.gz",
    "platform": null,
    "description": "# authservice\nThis API provides token-based authentication for user registration, login, and client credential management. It ensures secure communication by utilizing tokens for authentication. Users can register with unique usernames and passwords, authenticate using client credentials, retrieve client IDs and secrets, and regenerate client credentials as needed. The API supports various user roles, including 'user', 'admin', 'moderator', 'guest', and 'superadmin'.\n\nThis package is published in PyPI:\n```sh\nhttps://pypi.org/project/authservice/\n```\n## Requirements.\n\nPython 3.7+\n\n## Installation & Usage\n### pip install\nIf your package is hosted in PyPI:\n```sh\npip install authservice\n```\nIf the python package is hosted on a repository, you can install directly using:\n\n```sh\npip install git+https://github.com/CodeCrew24/authservice_python\n```\n(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/CodeCrew24/authservice_python`)\n\nThen import the package:\n```python\nimport authservice\n```\n\n### Setuptools\n\nInstall via [Setuptools](http://pypi.python.org/pypi/setuptools).\n\n```sh\npython setup.py install --user\n```\n(or `sudo python setup.py install` to install the package for all users)\n\nThen import the package:\n```python\nimport authservice\n```\n\n### Tests\n\nExecute `pytest` to run the tests.\n\n## Getting Started\n\nPlease follow the [installation procedure](#installation--usage) and then run the following:\n\n```python\n\nimport authservice\nfrom authservice.rest import ApiException\nfrom pprint import pprint\n\n# Defining the host is optional and defaults to https://auth-service-latest.onrender.com/auth\n# See configuration.py for a list of all supported configuration parameters.\nconfiguration = authservice.Configuration(\n    host = \"https://auth-service-latest.onrender.com/auth\"\n)\n\n\n\n# Enter a context with an instance of the API client\nwith authservice.ApiClient(configuration) as api_client:\n    # Create an instance of the API class\n    api_instance = authservice.DefaultApi(api_client)\n    username = 'johndoe' # str | User's username\n    password = 'password123' # str | User's password\n\n    try:\n        # Get client ID and secret\n        api_response = api_instance.client_get(username, password)\n        print(\"The response of DefaultApi->client_get:\\n\")\n        pprint(api_response)\n    except ApiException as e:\n        print(\"Exception when calling DefaultApi->client_get: %s\\n\" % e)\n\n```\n\n## Documentation for API Endpoints\n\nAll URIs are relative to *https://auth-service-latest.onrender.com/auth*\n\nClass | Method | HTTP request | Description\n------------ | ------------- | ------------- | -------------\n*DefaultApi* | [**client_get**](docs/DefaultApi.md#client_get) | **GET** /client | Get client ID and secret\n*DefaultApi* | [**login_client_post**](docs/DefaultApi.md#login_client_post) | **POST** /login/client | Logs in a user using client ID and secret\n*DefaultApi* | [**regenerate_client_credentials_post**](docs/DefaultApi.md#regenerate_client_credentials_post) | **POST** /regenerate-client-credentials | Regenerate client credentials\n*DefaultApi* | [**register_post**](docs/DefaultApi.md#register_post) | **POST** /register | Registers a new user\n\n\n## Documentation For Models\n\n - [ClientGet200Response](docs/ClientGet200Response.md)\n - [ClientGet401Response](docs/ClientGet401Response.md)\n - [LoginClientPost200Response](docs/LoginClientPost200Response.md)\n - [LoginClientPost401Response](docs/LoginClientPost401Response.md)\n - [RegenerateClientCredentialsPost200Response](docs/RegenerateClientCredentialsPost200Response.md)\n - [RegisterPost201Response](docs/RegisterPost201Response.md)\n - [RegisterPost400Response](docs/RegisterPost400Response.md)\n - [RegisterPost500Response](docs/RegisterPost500Response.md)\n\n\n<a id=\"documentation-for-authorization\"></a>\n## Documentation For Authorization\n\nEndpoints do not require authorization.\n\n\n## Author\n\n\n\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "With this SDK, Python developers can easily interact with the Auth API, enabling hassle-free implementation of user registration, login, and client credential management features within their applications.",
    "version": "0.0.2",
    "project_urls": {
        "Download": "https://github.com/CodeCrew24/authservice_python/archive/1.0.0.tar.gz",
        "GitHub Repo": "https://github.com/CodeCrew24/authservice_python",
        "Homepage": "https://github.com/CodeCrew24/authservice_python",
        "Release Notes": "https://github.com/CodeCrew24/authservice_python/releases/"
    },
    "split_keywords": [
        "token based auth",
        "bearer token",
        "auth service"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "cd7aed32dcac163747c8b05c6d7ce44d0f0d36dc18f9be991b6393ecca8944c5",
                "md5": "96337c8a2fd1bbf8a65e219a9d8b735c",
                "sha256": "7b6e1a9857f198b61e7ac5ce47bc738d85b3b7ad79f56d941d0d6ee009eba598"
            },
            "downloads": -1,
            "filename": "authservice-0.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "96337c8a2fd1bbf8a65e219a9d8b735c",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 34917,
            "upload_time": "2024-03-04T05:59:23",
            "upload_time_iso_8601": "2024-03-04T05:59:23.663806Z",
            "url": "https://files.pythonhosted.org/packages/cd/7a/ed32dcac163747c8b05c6d7ce44d0f0d36dc18f9be991b6393ecca8944c5/authservice-0.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "98beb04b6b7872244e96af56aaca3ea936e317be33064841a8eaad6b0d2dcb7a",
                "md5": "74dfd07e71d25c08c7c3bb9f51705bcb",
                "sha256": "3bc43a14c43179786d3471290fb812336f376c1c8135ef592cc8e53d8b9003a3"
            },
            "downloads": -1,
            "filename": "authservice-0.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "74dfd07e71d25c08c7c3bb9f51705bcb",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 23691,
            "upload_time": "2024-03-04T05:59:25",
            "upload_time_iso_8601": "2024-03-04T05:59:25.244985Z",
            "url": "https://files.pythonhosted.org/packages/98/be/b04b6b7872244e96af56aaca3ea936e317be33064841a8eaad6b0d2dcb7a/authservice-0.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-04 05:59:25",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "CodeCrew24",
    "github_project": "authservice_python",
    "travis_ci": true,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "tox": true,
    "lcname": "authservice"
}
        
Elapsed time: 0.23135s