Skip to main content

Jotform api integration dedicated for server usage which limits calls and calling form only if there is a new submission

Project description

CROSSMARK JOTFORM API

Reason of this library is to provide a simple and easy-to-use interface for interacting with the JotForm API. It is designed to be used by developers who want to integrate JotForm functionality into their applications.

PyPI version Python Version License CI/CD Pipeline Coverage Status Tests

📊 Code Coverage

This project maintains comprehensive test coverage to ensure code quality and reliability.

  • Current Coverage: ~51% and growing
  • Testing Framework: pytest with coverage.py
  • Coverage Reports: HTML, XML, and Terminal formats
  • CI Integration: Automated coverage reporting via GitHub Actions

Running Tests Locally

# Install development dependencies
pip install -r dev_requirements.txt
pip install -e .

# Run tests with coverage
./run_coverage.sh

# Or manually:
pytest --cov=src/crossmark_jotform_api --cov-report=term-missing --cov-report=html --cov-report=xml --cov-branch

# View HTML coverage report
open htmlcov/index.html


# Example command to run a specific unit test:
/home/raq/crossmark-jotform-api && python3 -m unittest tests.test_jotform_unit.TestJotFormUnit.test_create_and_delete_submission -v

Coverage Integration

We use the officially recommended approach for Python coverage reporting:

  • Local Development: coverage.py with HTML reports
  • CI/CD: GitHub Actions with Coveralls integration
  • Format: Cobertura XML for maximum compatibility

The project follows Coveralls' recommended setup for Python projects using:

  • GitHub Actions for CI
  • coverage.py to generate Cobertura XML reports
  • Official Coveralls GitHub Action for uploads

🚀 CI/CD Pipeline

This project includes a comprehensive CI/CD pipeline that ensures code quality and reliability:

Automated Testing

  • Multi-Python Version Testing: Tests run on Python 3.10, 3.11, and 3.12
  • Pull Request Validation: All PRs are automatically tested before merging
  • Coverage Threshold: Minimum 50% test coverage required for CI to pass
  • Quality Gates: Tests must pass before deployment to PyPI

Coverage Reporting

  • Dual Coverage Uploads: Reports sent to both Coveralls and Codecov
  • Branch Coverage: Comprehensive branch coverage tracking
  • HTML Reports: Detailed coverage reports available as CI artifacts
  • Coverage Badges: Real-time coverage status in README

Deployment

  • Automated PyPI Publishing: Packages are automatically published to PyPI on master branch pushes
  • Quality Assurance: Only code that passes all tests and coverage thresholds gets deployed
  • Trusted Publishing: Uses PyPI's trusted publishing for secure deployments

Workflow Files

  • .github/workflows/ci-cd.yml - Main CI/CD pipeline with testing and publishing
  • .github/workflows/test-coverage.yml - Dedicated coverage reporting and artifact generation

Examples

from jotform_api import JotformAPI

# Initialize the API with your API key
api = JotformAPI('YOUR_API_KEY')

# Get user details
user = api.get_user()
print(user)

# List all forms
forms = api.get_forms()
for form in forms:
  print(form['title'])

# Get submissions for a specific form
form_id = '1234567890'
submissions = api.get_form_submissions(form_id)
for submission in submissions:
  print(submission)

Contributing

Contributions are welcome! Please open an issue or submit a pull request on GitHub.

License

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

© 2025 Mirkan

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

crossmark_jotform_api-2.6.13.tar.gz (28.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

crossmark_jotform_api-2.6.13-py3-none-any.whl (18.1 kB view details)

Uploaded Python 3

File details

Details for the file crossmark_jotform_api-2.6.13.tar.gz.

File metadata

  • Download URL: crossmark_jotform_api-2.6.13.tar.gz
  • Upload date:
  • Size: 28.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for crossmark_jotform_api-2.6.13.tar.gz
Algorithm Hash digest
SHA256 5c326562c1ce9b23ebf2c47fdd3b75f560cfd9ac8b45fb90594819f70f31b07e
MD5 64f1e00c785cb091ea120ecd01f172bd
BLAKE2b-256 104b6013a701a3de1b776131b7e427459841d9088ce034a70b97122b5688cce8

See more details on using hashes here.

File details

Details for the file crossmark_jotform_api-2.6.13-py3-none-any.whl.

File metadata

File hashes

Hashes for crossmark_jotform_api-2.6.13-py3-none-any.whl
Algorithm Hash digest
SHA256 82595b9ea2ec825e31ba4e1b406d3f9354a2dcec024885a34b6ed446e2be08d5
MD5 bf9964b8e8289882c8f02f0a4248c0f4
BLAKE2b-256 7544f88d9bacf9b1b3c2f5398f6c98e7b2fea2f1ff135a9a9c7ed2a0ee483464

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page