Skip to main content

Connect with the CiviCRM APIv3 and APIv4 via HTTP and cv.

Project description

python: 3.8+ Tests Coveralls

Description

Clean and simple bindings to CiviCRM’s API. Both API v3 and API v4 are supported. CiviCRM’s API can be accessed either via REST or the command line tool cv.

Installation

pip install civicrmapi

Getting started

There are four ready to use api classes:

  • HttpApiV3 - REST API bindings for CiviCRM APIv3

  • HttpApiV4 - REST API bindings for CiviCRM APIv4

  • CvApiV3 - Using cv to access CiviCRM APIv3

  • CvApiV4 - Using cv to access CiviCRM APIv4

All you need to do is to initialize the api of your choice and use it:

from civicrmapi import CvApiV4

api = CvApiV4(cv='/path/to/cv', cwd='/path/to/civicrm/root')
params = {
    "contact_type": "Organization",
    "organization_name": "pretty org",
    }
result = api.Contact.create(params)

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

civicrmapi-0.5.tar.gz (12.8 kB view details)

Uploaded Source

Built Distribution

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

civicrmapi-0.5-py3-none-any.whl (15.2 kB view details)

Uploaded Python 3

File details

Details for the file civicrmapi-0.5.tar.gz.

File metadata

  • Download URL: civicrmapi-0.5.tar.gz
  • Upload date:
  • Size: 12.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for civicrmapi-0.5.tar.gz
Algorithm Hash digest
SHA256 43d8773e4560d0cb55d540c55f26e282a7ab8acad9548a004935b50ee95275eb
MD5 139e1ea8a2bfa4799f7ae53e4b09618a
BLAKE2b-256 fd2de060d1add73487751206bae20eb965c9f186db0d8d7acd87d7b4124ae787

See more details on using hashes here.

Provenance

The following attestation bundles were made for civicrmapi-0.5.tar.gz:

Publisher: publish.yml on thomst/civicrmapi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file civicrmapi-0.5-py3-none-any.whl.

File metadata

  • Download URL: civicrmapi-0.5-py3-none-any.whl
  • Upload date:
  • Size: 15.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for civicrmapi-0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 fcd6265b9d03272fcc02f2dc525aec4f41d2c6483ca67c61711200a530b11be0
MD5 4596be184dfa33a715774a57259cd9b2
BLAKE2b-256 78a90c47610594683c14b2c8dc15daf2b73cbc6e165ec3dc7113de0d70a91a62

See more details on using hashes here.

Provenance

The following attestation bundles were made for civicrmapi-0.5-py3-none-any.whl:

Publisher: publish.yml on thomst/civicrmapi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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