A Python wrapper for the Anaplan Bulk API
Project description
anaplan-api
Anaplan-API is a Python library wrapper for Anaplan Bulk API and Anaplan Authentication API.
Installation
Use the package manager pip to install Anaplan-API.
pip3 install anaplan_api
Usage
import logging
from anaplan_api import anaplan
from anaplan_api.AnaplanConnection import AnaplanConnection
from anaplan_api.KeystoreManager import KeystoreManager
logging.basicConfig(format='%(asctime)s,%(msecs)d %(name)s %(levelname)s %(message)s',
datefmt='%H:%M:%S',
level=logging.INFO)
logger = logging.getLogger(__name__)
if __name__ == '__main__':
keys = KeystoreManager(path='/keystore.jks', passphrase='', alias='', key_pass='')
auth = anaplan.generate_authorization(auth_type='Certificate', cert=keys.get_cert(), private_key=keys.get_key())
conn = AnaplanConnection(authorization=auth, workspace_id='', model_id='')
anaplan.file_upload(conn=conn, file_id="", chunk_size=5, data='/Users.csv')
results = anaplan.execute_action(conn=conn, action_id="", retry_count=3)
for result in results:
if result: # Boolean check of ParserResponse object, true if failure dump is available
print(result.get_error_dump())
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
License
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
anaplan-api-0.2.6.tar.gz
(43.7 kB
view hashes)
Built Distribution
Close
Hashes for anaplan_api-0.2.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fddc6677bea22074b791a271fbf79dc1378a9103af5a5e9c59494fd128c94e10 |
|
MD5 | a078284b464f90d09c6cd438ec73f3b6 |
|
BLAKE2b-256 | d7084828a089827350d70a8f3e9470a382bb58c0f39c71a5f1d8e094d08914f1 |