Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
imdb-pie
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
3
Issues
3
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
richardARPANET
imdb-pie
Commits
aaa03d01
Commit
aaa03d01
authored
May 22, 2018
by
richardARPANET
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
adds facade egs
parent
cfaf0419
Pipeline
#107
canceled with stage
Changes
3
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
240 additions
and
135 deletions
+240
-135
CLIENT.rst
CLIENT.rst
+135
-0
FACADE.rst
FACADE.rst
+97
-0
README.rst
README.rst
+8
-135
No files found.
CLIENT.rst
0 → 100644
View file @
aaa03d01
This diff is collapsed.
Click to expand it.
FACADE.rst
0 → 100644
View file @
aaa03d01
ImdbPie Facade Usage Examples
=============================
Init the Facade
---------------
.. code:: python
from imdbpie import ImdbFacade
imdb = ImdbFacade()
# Or, Specify a custom imdb-pie client instance for the facade to use
from imdbpie import Imdb
client = Imdb(locale='en_US')
imdb = ImdbFacade(client=client)
Exceptions
----------
For each method, if the resource cannot be found they will raise ``LookupError``,
for any other API status codes > 399 the client will raise ``ImdbAPIError``.
Get a title
-----------
.. code:: python
imdb.get_title(imdb_id='tt1023114')
Returns a ``Title`` object with the following attributes:
- certification
- creators
- credits
- directors
- episode
- episodes
- genres
- image
- imdb_id
- plot_outline
- rating
- rating_count
- release_date
- releases
- season
- stars
- title
- type
- writers
- year
Get a Name
----------
.. code:: python
imdb.get_name(imdb_id='nm0000151')
Returns a ``Name`` object with the following attributes:
- bios
- birth_place
- date_of_birth
- filmography
- gender
- image
- imdb_id
- name
Search for a name
-----------------
.. code:: python
imdb.search_for_name('Tom Hanks')
Returns a ``tuple`` containing ``NameSearchResult`` objects with the
following attributes:
- imdb_id
- name
Search for a title
------------------
.. code:: python
imdb.search_for_title('The Dark Knight')
Returns a ``tuple`` containing ``TitleSearchResult`` objects with the
following attributes:
- imdb_id
- title
- type
- year
README.rst
View file @
aaa03d01
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment