Skip to main content

SenhaSegura

Overview

The A2A module provides an unofficial interface for interacting with the SenhaSegura APIs. This module simplifies the integration of password management functionalities into your applications by offering support for both OAuth1 and OAuth2 authentication methods.

Features

Support for HTTP Methods: Easily make GET, POST, PUT, DELETE, HEAD, OPTIONS, and PATCH requests. Hostname Validation: Ensures that the provided hostname follows standard DNS rules. Endpoint Validation: Validates endpoint strings to prevent malformed URLs. Dynamic Method Binding: All HTTP methods are dynamically bound, allowing for intuitive usage. OAuth Authentication: Supports OAuth1 and OAuth2 for secure API access. Error Handling: Comprehensive error handling for authentication and request parameters.

Installation

You can use the SenhaSegura using one of the following methods:

pip: pip install senhasegura Git: git clone https://github.com/SrRenks/senhasegura.git

Usage

Initialize the A2A Class: To create an instance of the A2A module, specify the hostname and authentication parameters:

from senhasegura import A2A
import json
with open("oauth1_params.json", "r") as file:
    oauth1_params = json.loads(file.read())
a2a = A2A("senhasegura.yourcompany.com", "OAuth1", **oauth1_params)

Make API Calls: Use the instance to call API endpoints with the desired HTTP method:

response = a2a.get("/iso/coe/senha", params={"123": 123}, headers={"User-Agent": "example"})

Handle the Response: You can process the requests.Response as needed:

print(response.json())

Example

Here's a complete example of using the A2A module:

from senhasegura import A2A
import json

# Load OAuth1 parameters from a JSON file
with open("oauth1_params.json", "r") as file:
    oauth1_params = json.loads(file.read())

# Initialize with your credentials
a2a = A2A("senhasegura.yourcompany.com", "OAuth1", **oauth1_params)

# Make a GET request
response = a2a.get("/iso/coe/senha", params={"123": 123}, headers={"User-Agent": "example"})

# Print the response
print(response.json())

Contributing

Contributions are welcome! Please open an issue or submit a pull request for any improvements or features you would like to see.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Metadata

Release files for senhasegura 0.1.3

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

Source distribution (sdist)

Source distribution for senhasegura 0.1.3
File Size Uploaded Provenance Actions
senhasegura-0.1.3.tar.gz 4.0 kB Without provenance Details for senhasegura-0.1.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for senhasegura 0.1.3
File Interpreter ABI Platform Actions
senhasegura-0.1.3-py3-none-any.whl Python 3 none any Details for senhasegura-0.1.3-py3-none-any.whl

Total release size: 9.3 kB

Release files / senhasegura-0.1.3.tar.gz

Download URL senhasegura-0.1.3.tar.gz
Size 4.0 kB
Tags Source
SHA-256 checksum
How to use checksums
03c98a3e860ea6c7af4b9448d1585325ba085db9d33bcbfa0e3f06b68f33e445
BLAKE2b-256 checksum
How to use checksums
7fd887a297347384d2002ab1e55941a217d46bc5a1f3a138a858ac31bcd778a6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.3 CPython/3.11.2 Linux/6.1.0-28-amd64

Release files / senhasegura-0.1.3-py3-none-any.whl

Download URL senhasegura-0.1.3-py3-none-any.whl
Size 5.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
21a4b36dc749e2f98b0b7bf650779ed4d693da15a5e84860d635fa8e15849fd5
BLAKE2b-256 checksum
How to use checksums
607af5b138f836440c27c442da38e1cc2402df85a70a6e21678c55c54c03dec2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.3 CPython/3.11.2 Linux/6.1.0-28-amd64

Security for senhasegura 0.1.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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