SDK for MagicFeedback API
Project description
MagicFeedback SDK
A Python SDK for interacting with the MagicFeedback API
Installation
pip install MagicFeedback
Note: the distribution name on PyPI is
MagicFeedback, but the import name ismagicfeedback_sdk.
Usage
from magicfeedback_sdk import MagicFeedback
# Create a client instance
client = MagicFeedback("email", "password")
# Create a new feedback item
feedback_data = {
"name": "Test Feedback",
"type": "APP",
"identity": "MAGICFORM",
"integrationId": "your-integration-id",
"companyId": "YOUR_COMPANY",
"productId": "YOUR_PRODUCT",
"external_id": "YOUR EXTERNAL ID",
"answers": [
{"key": "score", "value": "4"},
{"key": "comment", "value": "Great service!"},
],
}
response = client.feedbacks.create(feedback_data)
print(response)
Required fields for feedbacks.create(): name, type, identity, integrationId, companyId, productId.
API Reference
The client exposes several sub-APIs:
client.feedbacks
create(feedback)— creates a new feedback item.get(filter=None)— lists feedback items.get_id(feedback_id, filter=None)— retrieves a specific feedback item.update(feedback_id, feedback)— updates a feedback item.delete(feedback_id)— deletes a feedback item.
client.contacts
create(contact),get(filter=None),update(contact_id, contact),delete(contact_id)
client.campaigns
create(campaign),get(filter=None)create_session(campaign_id, session),get_sessions(campaign_id, filter=None),get_sessions_feedbacks(campaign_id, filter=None)
client.metrics
get(filter=None)
client.products
get(filter=None)
client.companies
get(filter=None),get_id(id, filter=None)
client.integrations_questions
get(integration_id, filter=None)
client.reports
get(filter=None),get_newsletter(filter=None),update(report_id, report)
client.requests
get(filter=None),get_id(request_id, filter=None),update(request_id, request)
Logging
import logging
client.set_logging(logging.DEBUG)
Additional Information
- Authentication: the SDK requires a user / password obtained from the MagicFeedback platform.
- Error Handling: the SDK handles common API errors and raises appropriate exceptions.
- Custom base URL: pass
base_url="..."toMagicFeedback(...)to target a non-default environment.
License
This project is licensed under the MIT License.
Contact
For any questions or support, please contact farias@magicfeedback.io.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file magicfeedback-1.0.13.tar.gz.
File metadata
- Download URL: magicfeedback-1.0.13.tar.gz
- Upload date:
- Size: 7.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bc73483feb50b0854e3cd974f0b44c9734cf7072456562cb7605e45687a46ff1
|
|
| MD5 |
39729ba6a9723c24a47f0e3ade8244cf
|
|
| BLAKE2b-256 |
beb32f3ba31f4c38600f70a1c9bdf1b319792dbc57b3b27e52a5e08c32fbf546
|
File details
Details for the file magicfeedback-1.0.13-py3-none-any.whl.
File metadata
- Download URL: magicfeedback-1.0.13-py3-none-any.whl
- Upload date:
- Size: 11.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3c0dd136ad6bf4d74e93a8cd7d0a3ce794fa43e09617a2499a50309b662db56e
|
|
| MD5 |
8a31ee41281e8375d5aeb0dfe563f562
|
|
| BLAKE2b-256 |
e3f0b908fc39cd748283b6ef430976a45e7be1d49be84222c390bed362668603
|