Skip to content

Files

Latest commit

1a67d34 · May 27, 2025

History

History
64 lines (40 loc) · 2.28 KB
·

contributing.md

File metadata and controls

64 lines (40 loc) · 2.28 KB
·

Contributing to Fingerprint Server API SDK

Structure

Most files in the project are autogenerated by swagger-codegen with urllib3 library for python (default).

Code generation

You need swagger-codegen to run code generation. There are many ways described in the readme. In the project we use local jar file swagger-codegen-cli.jar.

You can just run ./generate.sh script and it will do all the work.

To download fresh OpenAPI schema run ./sync.sh

Configuration

Project configuration is described in config.json file. To read about available parameters run the command below:

java -jar ./bin/swagger-codegen-cli.jar config-help -l python

Testing the local source code of the SDK

To make requests using the local source code of the SDK:

  1. Define your Secret API key, Visitor ID, Request ID and Region by creating a .env file at the root of the repository. (See example))
  2. Run the following commands:
pip install -r requirements.txt
python run_checks.py

Test environment

You need to install python and pip. Then you can run:

pip install -r requirements.txt
pip install -r test-requirements.txt

Running tests

pytest

How to publish

We use changesets for handling release notes. If there are relevant changes, please add them to changeset via pnpm exec changeset. You need to run pnpm install before doing so.

Pre-release flow

Pre-release will be created after merging pr to the dev branch and running the release workflow.

Python uses PEP 440 for versions format, so we convert a pre-release version from semver to PEP 440 in the ./generate.sh.