Client library for They Said So Quotes API
npm install --save @datafire/quotes_rest
let quotes_rest = require('@datafire/quotes_rest').create({
"X-TheySaidSo-Api-Secret": ""
});
.then(data => {
console.log(data);
});
They Said So Quotes API offers a complete feature rich REST API access to its quotes platform. This is the documentation for the world famous quotes API. If you are a subscriber and you are trying this from a console add 'X-TheySaidSo-Api-Secret' header and add your api key as the header value. You can test and play with the API right here on this web page. For using the private end points and subscribing to the API please visit https://theysaidso.com/api.
Gets Quote of the Day
. Optional category
param determines the category of returned quote of the day
quotes_rest.qod.get({}, context)
- input
object
- category
string
: QOD Category - language
string
: Language of the QOD. The language must be supported in our QOD system.
- category
- output QuoteResponse
Gets a list of Quote of the Day
Categories.
quotes_rest.qod.categories.get({}, context)
- input
object
- language
string
: Language of the QOD category. The language must be supported in our QOD system. - detailed
boolean
: Return detailed information of the categories. Note the data format changes between the two values of this switch.
- language
Output schema unknown
Gets a list of supported languages for Quote of the Day
.
quotes_rest.qod.languages.get(null, context)
This action has no parameters
Output schema unknown
Delete a qshow.
quotes_rest.qshow.delete({
"id": ""
}, context)
- input
object
- id required
string
: Qshow ID
- id required
Output schema unknown
Gets a details about a qshow.
quotes_rest.qshow.get({
"id": ""
}, context)
- input
object
- id required
string
: Qshow ID
- id required
Output schema unknown
Update an existing qshow.
quotes_rest.qshow.patch({
"id": ""
}, context)
- input
object
- id required
string
: Qshow ID - title
string
: Qshow title - description
string
: Qshow description - tags
array
: Tags for the qshow
- id required
Output schema unknown
Create and add a new qshow to your private collection.
quotes_rest.qshow.put({
"title": ""
}, context)
- input
object
- title required
string
: Qshow title - description
string
: Qshow description - tags
array
: Tags for the qshow
- title required
Output schema unknown
Get the list of Qshows in They Said So platform.
quotes_rest.qshow.list.get({}, context)
- input
object
- start
integer
: Response is paged. This parameter controls where response starts the listing at - public
boolean
: Should include public qshows or not in the list
- start
Output schema unknown
Get the quotes in a given Qshow.
quotes_rest.qshow.quotes.get({
"id": ""
}, context)
- input
object
- id required
string
: Qshow ID
- id required
Output schema unknown
Add a quote to a given Qshow.
quotes_rest.qshow.quotes.add.post({
"id": "",
"quoteid": ""
}, context)
- input
object
- id required
string
: Qshow ID - quoteid required
string
: Quote ID to add the qshow collection
- id required
Output schema unknown
Remove a quote to a given Qshow.
quotes_rest.qshow.quotes.remove.post({
"id": "",
"quoteid": ""
}, context)
- input
object
- id required
string
: Qshow ID - quoteid required
string
: Quote ID to remove from the qshow collection
- id required
Output schema unknown
Delete a quote. The user needs to be the owner of the quote to be able to delete it.
quotes_rest.quote.delete({
"id": ""
}, context)
- input
object
- id required
string
: Quote ID
- id required
Output schema unknown
Gets a Quote
with a given id
.
quotes_rest.quote.get({}, context)
- input
object
- id
string
: Quote ID
- id
- output QuoteResponse
Update a quote
quotes_rest.quote.patch({
"id": ""
}, context)
- input
object
- id required
string
: Quote ID - quote
string
: Quote - author
string
: Quote Author - language
string
: Language. If not supplied an auto detection mechanism will be used to detect a language. - tags
string
: Comma Separated tags
- id required
Output schema unknown
Add a new quote to your private collection. Same as 'PUT' but added since some clients don't handle PUT well.
quotes_rest.quote.post({
"quote": ""
}, context)
- input
object
- quote required
string
: Quote - author
string
: Quote Author - tags
string
: Comma Separated tags - language
string
: Language. If not supplied an auto detection mechanism will be used to detect a language.
- quote required
Output schema unknown
Add a new quote to your private collection.
quotes_rest.quote.put({
"quote": ""
}, context)
- input
object
- quote required
string
: Quote - author
string
: Quote Author - tags
string
: Comma Separated tags - language
string
: Language. If not supplied an auto detection mechanism will be used to detect a language.
- quote required
Output schema unknown
Gets a list of popular author names in the system.
quotes_rest.quote.authors.popular.get({}, context)
- input
object
- language
string
: Language. A same author may have quotes in two or more different languages. So for example 'Mahatma Gandhi' may be returned for language "en"(English), and "மஹாத்மா காந்தி" may be returned when the language is "ta" (Tamil). - detailed
boolean
: Should return detailed author information such asbirthday
,death date
,occupation
,description
etc. Only available at certain subscription levels. - start
integer
: Response is paged. This parameter controls where response starts the listing at - limit
integer
: Response is paged. This parameter controls how many is returned in the result. The maximum depends on the subscription level.
- language
Output schema unknown
Gets a list of author names in the system.
quotes_rest.quote.authors.search.get({}, context)
- input
object
- query
string
: Text string to search for in author names - language
string
: Language. A same author may have quotes in two or more different languages. So for example 'Mahatma Gandhi' may be returned for language "en"(English), and "மஹாத்மா காந்தி" may be returned when the language is "ta" (Tamil). - detailed
boolean
: Should return detailed author information such asbirthday
,death date
,occupation
,description
etc. Only available at certain subscription levels. - start
integer
: Response is paged. This parameter controls where response starts the listing at - limit
integer
: Response is paged. This parameter controls how many is returned in the result. The maximum depends on the subscription level.
- query
Output schema unknown
Gets a list of popular Quote
Categories.
quotes_rest.quote.categories.popular.get({}, context)
- input
object
- start
integer
: Response is paged. This parameter controls where response starts the listing at - limit
integer
: Response is paged. This parameter controls how many is returned in the result. The maximum depends on the subscription level.
- start
Output schema unknown
Gets a list of Quote
Categories matching the query string.
quotes_rest.quote.categories.search.get({}, context)
- input
object
- query
string
: Text string to search for in the categories - start
integer
: Response is paged. This parameter controls where response starts the listing at - limit
integer
: Response is paged. This parameter controls how many is returned in the result. The maximum depends on the subscription level.
- query
Output schema unknown
Remove the disLike for the given Quote as a user of the API Key.
quotes_rest.quote.dislike.delete({
"quote_id": ""
}, context)
- input
object
- quote_id required
string
: Quote ID
- quote_id required
Output schema unknown
Dislike the given Quote as a user of the API Key. Same as put
but a convenient alias for those clients that don't support put
cleanly.
quotes_rest.quote.dislike.post({
"quote_id": ""
}, context)
- input
object
- quote_id required
string
: Quote ID
- quote_id required
Output schema unknown
Dislike the given Quote as a user of the API Key. Some clients don't cleanly support PUT
, in such scenarios use the POST
version of this.
quotes_rest.quote.dislike.put({
"quote_id": ""
}, context)
- input
object
- quote_id required
string
: Quote ID
- quote_id required
Output schema unknown
Delete a quote image. The user needs to be the owner of the quote image to be able to delete it.
quotes_rest.quote.image.delete({
"id": ""
}, context)
- input
object
- id required
string
: Quote Image ID
- id required
Output schema unknown
Gets a Quote image for a given id. Response can be an image file as a binary or a base64 encoded contents wrapped in json. TODO
quotes_rest.quote.image.get({
"id": ""
}, context)
- input
object
- id required
string
: Quote Image id - binary
boolean
: Should the response be a direct file download of the image or a base64 encoded image file wrapped in json?
- id required
Output schema unknown
Create a new quote image for a given quote. Choose background colors/images , choose different font styles and generate a beautiful quote image. Did you just had a feeling of being a god or what?!
quotes_rest.quote.image.put({
"quote_id": ""
}, context)
- input
object
- quote_id required
string
: Quote id - bgimage_id
string
: Background Image id ( Will override bgcolor if supplied) - bg_color
string
: Background Color(if background image id is not supplied) - font_id
string
: Font id - text_color
string
: Text Color - text_size
string
: Text/font size - halign
string
: Horizontal text Alignment Value - valign
string
: Vertical text Alignment Value - width
integer
: Image Width(By default this takes the width of the background image) - height
integer
: Image Height(By default this takes the height of the background image) - branding
boolean
: Disable They Said So branding (Only available in certain subscription levels. Ignored in other levels) - include_transparent_layer
boolean
: Should include a transparent layer between the text and the background image? This helps when the background image is bright and obscures the text.
- quote_id required
Output schema unknown
Delete a background image file. The user needs to be the owner of the background image to be able to delete it.
quotes_rest.quote.image.background.delete({
"id": ""
}, context)
- input
object
- id required
string
: Font ID
- id required
Output schema unknown
Add an image for use later as a quote background image.
quotes_rest.quote.image.background.post({
"image": ""
}, context)
- input
object
- image required
string
: Image file to add to your collection (png/jpg/gif are supported) - tags
string
: Optional comma separated tags
- image required
Output schema unknown
Lists background images in your private collection.
quotes_rest.quote.image.background.list.get({}, context)
- input
object
- start
integer
: Response is paged. This parameter determines where the response should start.
- start
Output schema unknown
Searches for a background image with a given tag.
quotes_rest.quote.image.background.search.get({}, context)
- input
object
- query
string
: Tag string
- query
Output schema unknown
Add a tag to a given Image.
quotes_rest.quote.image.background.tags.add.post({
"id": "",
"tags": ""
}, context)
- input
object
- id required
string
: Image ID - tags required
string
: Comma Separated tags
- id required
Output schema unknown
Remove a tag from a given Image.
quotes_rest.quote.image.background.tags.remove.post({
"id": "",
"tags": ""
}, context)
- input
object
- id required
string
: Image ID - tags required
string
: Comma Separated tags
- id required
Output schema unknown
Delete a font file. The user needs to be the owner of the font to be able to delete it.
quotes_rest.quote.image.font.delete({
"id": ""
}, context)
- input
object
- id required
string
: Font ID
- id required
Output schema unknown
Add a font file for use later in creating a quote image. This is essentially a PUT
but not many clients handle PUT with binary stream i.e. a file, gracefully.
quotes_rest.quote.image.font.post({
"font": ""
}, context)
- input
object
- font required
string
: Font file to add to your collection (ttf/otf are supported) - tags
string
: Optional comma separated tags
- font required
Output schema unknown
Lists background images in your private collection.
quotes_rest.quote.image.font.list.get({}, context)
- input
object
- start
integer
: Response is paged. This parameter determines where the response should start.
- start
Output schema unknown
Searches for a font with a given tag.
quotes_rest.quote.image.font.search.get({}, context)
- input
object
- query
string
: Tag string
- query
Output schema unknown
Add a tag to a given font.
quotes_rest.quote.image.font.tags.add.post({
"id": "",
"tags": ""
}, context)
- input
object
- id required
string
: Font ID - tags required
string
: Comma Separated tags
- id required
Output schema unknown
Remove a tag from a given Font.
quotes_rest.quote.image.font.tags.remove.post({
"id": "",
"tags": ""
}, context)
- input
object
- id required
string
: Font ID - tags required
string
: Comma Separated tags
- id required
Output schema unknown
Gets a Random Quote image. Optional category
param determines the category of quote used in the image. Optional author
param gets the quote image of a given author.
quotes_rest.quote.image.search.get({}, context)
- input
object
- category
string
: Quote Category - author
string
: Quote Author - private
boolean
: Should search private collection. Default searches public image collection.
- category
Output schema unknown
Remove the Like for the given Quote as a user of the API Key.
quotes_rest.quote.like.delete({
"quote_id": ""
}, context)
- input
object
- quote_id required
string
: Quote ID
- quote_id required
Output schema unknown
Like the given Quote as a user of the API Key. Same as PUT
but a convenient alias for those clients that don't support PUT
cleanly.
quotes_rest.quote.like.post({
"quote_id": ""
}, context)
- input
object
- quote_id required
string
: Quote ID
- quote_id required
Output schema unknown
Like the given Quote as a user of the API Key. Some clients don't cleanly support PUT
, in such scenarios use the POST
version of this.
quotes_rest.quote.like.put({
"quote_id": ""
}, context)
- input
object
- quote_id required
string
: Quote ID
- quote_id required
Output schema unknown
Get the list of quotes in your private collection.
quotes_rest.quote.list.get({}, context)
- input
object
- start
integer
: Response is paged. This parameter controls where response starts the listing at - limit
integer
: Response is paged. This parameter controls how many is returned in the result.
- start
Output schema unknown
Gets a Random Quote
. When you are in a hurry this is what you call to get a random famous quote.
quotes_rest.quote.random.get({}, context)
- input
object
- language
string
: Language of the Quote. The language must be supported in our system. - limit
integer
: No of quotes to return. The max limit depends on the subscription level.
- language
- output QuoteResponse
Search for a Quote
in They Said So platform. Optional category
, author
, minlength
, maxlength
params determines the filters applied while searching for the quote.
quotes_rest.quote.search.get({}, context)
- input
object
- category
string
: Quote Category - author
string
: Quote Author - minlength
integer
: Quote minimum Length - maxlength
integer
: Quote maximum Length - query
string
: keyword to search for in the quote - private
boolean
: Should search private collection? Default searches public collection. - language
string
: Language of the Quote. The language must be supported in our system. - limit
integer
: No of quotes to return. The max limit depends on the subscription level. - sfw
boolean
: Should search only SFW (Safe For Work) quotes?
- category
- output QuoteResponse
Add a tag to a given Quote.
quotes_rest.quote.tags.add.post({
"id": "",
"tags": ""
}, context)
- input
object
- id required
string
: Quote ID - tags required
string
: Comma Separated tags
- id required
Output schema unknown
Remove a tag from a given quote.
quotes_rest.quote.tags.remove.post({
"id": "",
"tags": ""
}, context)
- input
object
- id required
string
: Quote ID - tags required
string
: Comma Separated tags
- id required
Output schema unknown
- NewQuote
object
- tags
array
: Array of tags/categories.- items
string
- items
- author
string
: Author name of quote. - quote required
string
: The Quote.
- tags
- QOD
- tags
array
: Array of tags/categories.- items
string
- items
- author
string
: Author name of quote. - quote required
string
: The Quote. - id required
string
: Unique identifier representing a specific quote in theysaidso.com. - image
string
: Image URL that can be used for background to display this quote. - length
integer
: Length of the quote string. - date required
string
: Date this quote of the day belongs to
- tags
- Quote
- tags
array
: Array of tags/categories.- items
string
- items
- author
string
: Author name of quote. - quote required
string
: The Quote. - id required
string
: Unique identifier representing a specific quote in theysaidso.com. - image
string
: Image URL that can be used for background to display this quote. - length
integer
: Length of the quote string.
- tags
- QuoteResponse
object
- contents
object
- quotes
array
: List of quotes- items Quote
- quotes
- success
string
: Metadata about this successful call
- contents