Skip to main content

LordOfTheRings SDK

Installation

pip install AaronBlaser-SDK==1.0.1

Usage

  1. Import the LordOfTheRings class
from lordoftherings import LordOfTheRings
  1. Initialize the class with your API Token
api = LordOfTheRings('YOUR API TOKEN')
  1. Make calls to the API
  • /movie
all_movies = api.movies().get_all().fetch()
  • /movie/{id}
movie = api.movies("5cd95395de30eff6ebccde56").get()
  • /movie/{id}/quote
movie_quotes = api.movies("5cd95395de30eff6ebccde5b").quotes.get_all().fetch()
  • /quote
quotes = api.quotes().get_all().fetch()
  • /quote/{id}
single_quote = api.quotes("5cd96e05de30eff6ebccebc9").get()
  1. Make calls using sorting, filtering, and pagination
  • Filtering
match = api.movies().get_all().filter_by(name='The Lord of the Rings Series').fetch() 
negate_match = api.movies().get_all().filter_by(name=('not', 'The Lord of the Rings Series')).fetch() 
include = api.movies().get_all().filter_by(name=['The Lord of the Rings Series', 'The Desolation of Smaug']).fetch()
exclude = api.movies().get_all().filter_by(name=[('not', 'The Lord of the Rings Series'), ('not', 'The Desolation of Smaug')]).fetch()
less_than = api.movies().get_all().filter_by(budgetInMillions=('<', 100)).fetch() 
greater_than = api.movies().get_all().filter_by(runtimeInMinutes=('>', 160)).fetch()
  • Sorting
sorted_movies = api.movies().get_all().sort_by("name:asc").fetch()
  • Pagination
paged_movies_1 = api.movies().get_all().limit(2).fetch()
paged_movies_2 = api.movies().get_all().limit(3).page(2).fetch()
paged_movies_3 = api.movies().get_all().limit(1).page(1).offset(1).fetch()
  • Combine all Three
filter_sorted_paged = api.movies().get_all().limit(5).filter_by(name=('not', 'The Lord of the Rings Series')).sort_by('name:asc').fetch()

Testing

  1. Unit Tests

There is a file called test_lordoftherings.py in the tests folder that has some unit tests in it. Run this file to run the tests

  • Replace with your token
    self.auth_token = 'YOUR API TOKEN'
    
  1. Example Usage File

There is a file called test_usage.py in the tests that has many examples of how you can use this SDK. Add your auth token and uncomment the examples you want to run, then run the file.

  • Replace with your token
    api = LordOfTheRings('YOUR API TOKEN')
    

Metadata

Release files for AaronBlaser-SDK 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for AaronBlaser-SDK 1.0.1
File Size Uploaded Provenance
AaronBlaser-SDK-1.0.1.tar.gz 6.2 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for AaronBlaser-SDK 1.0.1
File Interpreter ABI Platform
AaronBlaser_SDK-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 13.5 kB

Release files / AaronBlaser-SDK-1.0.1.tar.gz

Download URL AaronBlaser-SDK-1.0.1.tar.gz
Size 6.2 kB
Tags Source
SHA-256 checksum
How to use checksums
3d9dcf90755d6a323152e55c56c84585386508beec6d449aaf11ff55ee3ee4a1
BLAKE2b-256 checksum
How to use checksums
3ec4c246abeb7acda982f69ebd1755a6c9c33c80ee23242860e334159c1005e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.3

Release files / AaronBlaser_SDK-1.0.1-py3-none-any.whl

Download URL AaronBlaser_SDK-1.0.1-py3-none-any.whl
Size 7.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8d7b27ff68eeae785d775db3e841b0cd832074401381b27ed1087d512ebc0392
BLAKE2b-256 checksum
How to use checksums
b57a3088294ba81818bf6d6e368a99ad7e4d8256a4c866c635644b50f975f51c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.3

Security for AaronBlaser-SDK 1.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page