Skip to main content

No project description provided

Project description

Codacy Badge Codacy Badge CI/CD Workflow Code style: black

Valued Python Client

A Python client library for sending events to Valued.

Installation

$ pip install valued

Usage

You can create a valued.Client instance and call action, sync etc directly on the client.

import os
import valued

# Get the token for authentication.
token = os.environ.get("VALUED_TOKEN") # or wherever you store credentials

# Create a client
client = valued.Client(token)

# Record an action
client.action("report.generated", {
  "customer": { "id": 12 },
  "user": { "id": 123 },
  "attributes": { "format": "pdf" }
})

# Sync user data
client.sync_user({
  "id": 123,
  "name": "Josh Kalderimis",
  "email": "josh@valued.app",
  "location": { "country": "NZ", "region": "Wellington" }
})

Contributing

All commits messages should be in the Angluar commit style

  • feat: A new feature.
  • fix: A bug fix.
  • docs: Documentation changes.
  • style: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc).
  • refactor: A code change that neither fixes a bug nor adds a feature.
  • perf: A code change that improves performance.
  • test: Changes to the test framework.
  • build: Changes to the build process or tools.

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

valued-0.2.2.tar.gz (3.7 kB view hashes)

Uploaded Source

Built Distribution

valued-0.2.2-py3-none-any.whl (3.7 kB view hashes)

Uploaded Python 3

Supported by

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