Skip to main content

Python client for https://server.odecloud.app

Project description

Official OdeServer Python API's Client

Getting Started & Usage

  1. Installation:
  • Use Poetry:
    $ poetry add odecloud
    
  • Or, use Pip:
    $ pip install odecloud
    
  1. Instantiate your connection to OdeCloud's API:
  • If you don't know your client credentials:

    api = Api('https://server.odecloud.app/api/v1') # All API calls will be made to this domain.
    api.login('your-email@here.com', 'your_password')
    
  • If you already know your client credentials:

    api = Api(
        base_url='https://server.odecloud.app/api/v1', # All API calls will be made to this domain
        client_key='YOUR CLIENT KEY',
        client_secret='YOUR CLIENT SECRET',
    )
    
  1. Now, any calls can be made to OdeCloud's API. Examples below:
    api.comments.get(createdBy=random_user_id) # GET /api/v1/comments?createdBy=random_user_id/
    api.comments.post(data=expected_payload) # POST /api/v1/comments/
    api.comments(random_comment_id).patch(data=expected_payload) # PATCH /api/v1/comments/random_comment_id/
    api.comments(random_comment_id).delete() # DELETE /api/v1/comments/random_comment_id/
    

Happy coding!

Publishing to PyPI

  1. On the root of the directory, open up pyproject.toml
  2. Bump the version by the following guideline:
    • Our version numbering follows Major.Minor.Patch (e.g. 2.10.1)
      • Major: Stable release.
      • Minor: Incremental changes--including new API, remove API, or change of behavior of the API.
      • Patch: Small efficient changes--including a fixed to a bug.
    • Note: in regards to Patch if the old functionality was always erroneous, then it will be considered a Patch.
  3. Publish a new tag on the repository by going to https://gitlab.com/odetech/python_odecloud/-/tags/new.
    • Note: make sure that the "Tag Name" is an exact match to the version inside pyproject.toml on step #2.
    • In regards to the "Release notes": we encourage detail and consistent format in order for other developers to understand the new version update.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

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

odecloud-0.14.0.tar.gz (6.4 kB view details)

Uploaded Source

Built Distribution

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

odecloud-0.14.0-py3-none-any.whl (6.8 kB view details)

Uploaded Python 3

File details

Details for the file odecloud-0.14.0.tar.gz.

File metadata

  • Download URL: odecloud-0.14.0.tar.gz
  • Upload date:
  • Size: 6.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.12 CPython/3.10.1 Linux/5.4.109+

File hashes

Hashes for odecloud-0.14.0.tar.gz
Algorithm Hash digest
SHA256 8fea1d7f43c5ff22a17db6b212d006a167e2c80176ee1218e6d6375821763f08
MD5 ee4dcacda9eb4d3153a93e1f48700f88
BLAKE2b-256 7ab4041096cbaee2b7c8807ef122c2525c154de17b9567aa9b40aa31eabcbfe3

See more details on using hashes here.

File details

Details for the file odecloud-0.14.0-py3-none-any.whl.

File metadata

  • Download URL: odecloud-0.14.0-py3-none-any.whl
  • Upload date:
  • Size: 6.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.12 CPython/3.10.1 Linux/5.4.109+

File hashes

Hashes for odecloud-0.14.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2f062bcb7417fd95908003d484cb8c680a734e521447922db638fbb5d7b5308b
MD5 72589c28b43caed6f0bed8bfbdaf32c6
BLAKE2b-256 b03b9e2113b60ca1ffb2a2291aafed3ffd043a68a883e493d31c527a08a0dbad

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