Skip to main content

A collection of scripts to easily use the API of OCD Datalake

Project description

 ____        _        _       _          ____            _       _ 
|  _ \  __ _| |_ __ _| | __ _| | _____  / ___|  ___ _ __(_)_ __ | |_ ___
| | | |/ _` | __/ _` | |/ _` | |/ / _ \ \___ \ / __| '__| | '_ \| __/ __|
| |_| | (_| | || (_| | | (_| |   <  __/  ___) | (__| |  | | |_) | |_\__ \
|____/ \__,_|\__\__,_|_|\__,_|_|\_\___| |____/ \___|_|  |_| .__/ \__|___/
                                                          |_|

datalake

Datalake scripts

How to use

Installation

With Python 3.6+:

$ pip install datalake-scripts

Using a script

The cli can be used with:

$ ocd-dtl <command> <parameter>

Check ocd-dtl -h for help, including the list of commands available.

You can also use a script directly by using the following command: <script_name> <script_options>.

/!\ Make sure to use utf-8 without BOM when providing a file (-i option)

Environment variables

Authentication

In case you don't want to enter credential for each commands and you are on a secured terminal, set those variables:

  • OCD_DTL_USERNAME email address used to login on Datalake API/GUI.
  • OCD_DTL_PASSWORD password used to login on Datalake API/GUI.

They are independent and one can be used without the other if you wish.

Throttling

For throttling the request, those two environment variable can be used:

  • OCD_DTL_QUOTA_TIME define, in seconds, the time before resetting the requests limit, default is 1 second.
  • OCD_DTL_REQUESTS_PER_QUOTA_TIME define the number of request to do at maximum for the given time, default is 5 queries.

Please don't exceed the quota marked here for each endpoint

Cli parameters

Parameters common and optional for all commands:

--debug display more information for debugging purposes
-e to change the environment {preprod, prod}, default is prod
-o will set the output file as the API gives it.
-q will quiet the verbosity of the program (but still show errors / warnings)

For information about each command and more, please check the documentation directory

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

datalake-scripts-0.1.4.tar.gz (13.2 kB view details)

Uploaded Source

Built Distribution

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

datalake_scripts-0.1.4-py3-none-any.whl (20.4 kB view details)

Uploaded Python 3

File details

Details for the file datalake-scripts-0.1.4.tar.gz.

File metadata

  • Download URL: datalake-scripts-0.1.4.tar.gz
  • Upload date:
  • Size: 13.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.6.9

File hashes

Hashes for datalake-scripts-0.1.4.tar.gz
Algorithm Hash digest
SHA256 94a12427f2f93c39a1f77bd48905aa82b40be8599b8564a5e5bd60d9be317b48
MD5 d7ac503a9473750ae73cf524dbe9aed4
BLAKE2b-256 d06e467bcc5e8dee95d8d7baf734f8b1efc980a6972b924e28803d6c66e24860

See more details on using hashes here.

File details

Details for the file datalake_scripts-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: datalake_scripts-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 20.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.6.9

File hashes

Hashes for datalake_scripts-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 43545a7d012c6f0084fcd5618ac433b008fff7a8feea91ac31d49b7c0ede5a9c
MD5 86756ed40d6ecb71d887afac3f4d214c
BLAKE2b-256 d8e6e7098d4ffdf55d736e96e4e424db6ff72509adf0be4ede74e73c7d0e42c2

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