semvec/pypi-packages huggingface dataset:
veracross-client 0.0.4
Python wrapper for communicating with the Veracross API
Requires Python: >=3.8

# veracross-client

This project provides a Python wrapper for the Veracross API. It enables Veracross administrators to access, manipulate, and manage data programmatically with Python.

## Installation

Install the latest version of veracross-client by running

```
pip install --upgrade veracross-client
```

## Getting Started

To begin, you need to create an OAuth Application in Veracross using the documentation found at [Veracross Community: OAuth Applications and Veracross Overview](https://community.veracross.com/s/article/OAuth-Applications-and-Veracross-Overview). Be sure to set the scopes to cover the data you would like to access.

After creating an OAuth Application and setting its scopes, create a file named config.json similar to sample_config.json provided in this repository. It should look like:

```
{
    "client_id": "OAuth application client id",
    "client_secret": "OAuth application client secret",
    "school_route": "school route that appears in Veracross URL"
}

```

To create a client for connecting to Veracross API, use the following code:

```
import veracross_client as vc
import json

secrets =json.loads(open('config.json').read())

client = vc.VeracrossClient(school_route=secrets['school_route'],
                            client_id=secrets['client_id'],
                            client_secret=secrets['client_secret'],
                            scopes=["_scope 1_","_scope 2_",...])
```

Be sure to replace the list of scopes with the scopes added to the OAuth Application. The veracross-client wrapper will return an error if a function with inappropriate scopes is used.

Once the client is initiated, use the client's methods to access individual endpoints of the Veracross API. All GET methods will return a dataframe.

## Contributing

This wrapper is still in development. Methods for individual endpoints are not guaranteed to work. Please post issues with the name of the method that is not working along with a description of the error being encountered.
Zatca-Csr-Generator 0.1.0
Zatca Csr Generator generates the certificate signing request for zatca phase2, It is takes informations and parameters from the user and returns the csr in base64 ready to submit to zatca

# Csr and Private Key generator for Zatca Phase2
Generate Private Key with EC Curve and CSR for the Zatca Phase2 for the complience CSID
## Installation

To use the Zatca Csr Generator, you need to have cryptography installed. You can install it using pip:

```shell
pip install cryptography,zatca_csr_generator
```

# Usage
First, import the necessary modules:

Then, import and create an instance of the CsrGenerator class:

certificate=GenerateCSR()

# Loading an method to obtain private key and certificate signing request
To load an image from a file, use the load_image method:

1. csr_type 
   e.g for 'sandbox' |'simulation' | 'production'. 
2. C = country
    country with max 2 length.
3. CN = common name
4. O = organization
5. OU = organization unit
6. SN = Serial number e.g 
   1-name of the company|2-version|3-uuid
     
7. UID = Tax Registration No (15 Digits)
8. TITLE = Type of business e.g 1000,0100, 1100
   + B2B =0100
   + B2C= 1000
   + Both= 1100
9. CATEGORY = Type of business
10. ADDRESS  = Registered Business Address

```
privatekey,csr= certificate.generate_csr.(csr_type, C, CN, O, OU, SN, UID, TITLE, CATEGORY, ADDRESS)
```
privatekey will return the string for the private key and 

# Example

```
from zatca_csr_generator import  GenerateCSR

certificate=GenerateCSR()


privatekey,csr= certificate.generate_csr.("production","SA", "TST", "TST",
                                          "TST", "1-TST|2-TEST|3-uuid",
                                          "3210124145101243", "1100", "Information Technology", "RHSX46590")

print(privatekey)
print(csr)
```

# Contributing
Contributions are welcome! If you find any issues or have suggestions for improvements, please create an issue or submit a pull request.


# License
This project is open source and licensed under the MIT License.

# Contact

For any questions or inquiries, please contact:

- Muhammad Bilal
- Email: bilaljmal@gmail.com