Difference between revisions of "API Access"

From Anime Characters Database Wiki
Jump to navigation Jump to search
(Added information and changed some wording.)
 
(9 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Do you have a project that could benefit from the data on Anime Characters Database? As a way to help pay the server bills, I offer my services to develop a custom API to suit for your needs for a small fee.
 
 
[http://www.animecharactersdatabase.com/api_series_characters.php Current API Tools]
 
 
 
==How Not To Get Banned==
 
==How Not To Get Banned==
  
===First, you need to set a HTTP_USER_AGENT for the tool you will be accessing ACDB from.===
+
===First: Set a HTTP_USER_AGENT for the tool you will be accessing ACDB from.===
  
Using the wrong user agent will ban your IP for the day ( 402 Payment Required )
+
If Python,Perl,etc is in your user agent, you will get errors like
 +
( 402 Payment Required )  
 +
If you leave it with the default, you will be joining a pool of people who also left it default, and together may pose a DDoS threat. This is why I auto ban curl/python/wget any any other popular tool.
  
If you leave it with the default, you will be joining a pool of people who alos left it default, and together may pose a DDoS threat. This is why I auto ban curl/python/wget.
+
To safely check your user agent, visit this page:
 +
https://www.animecharactersdatabase.com/vars.php
  
To safely check your user agent, visit this page: https://www.animecharactersdatabase.com/vars.php
+
===Second: Rate limit your requests.===
 +
Respectfully, limit your bot to 1 request per second.
  
===Second, you need to rate limit your requests.===
+
==Current API tools==
 
+
[http://www.animecharactersdatabase.com/api_series_characters.php Current API Tools]
30 pages in 3 seconds will trigger a DoS ban. ( 429 Too Many Requests )
+
==Characters==
  100 pages in 100 seconds will trigger a day ban ( 503 Service Unavailable )
+
[https://www.animecharactersdatabase.com/hosted/characters.sql.gz Characters API]
3000 pages in day will trigger a day ban ( 503 Service Unavailable )
+
==Titles==
 +
[https://www.animecharactersdatabase.com/hosted/publishers.sql.gz Titles API]
 +
==Assignments==
 +
[https://www.animecharactersdatabase.com/hosted/assignments.sql.gz Assignments API]
 +
==License==
 +
[https://opendatacommons.org/licenses/odbl/summary/index.html Open Database License - Terms of Legal Use]
 +
==Changes==
 +
  January 20th 2021
 +
When requesting birthdays
 +
*character_image now returns the full sized character image
 +
*character_thumb has been added to return the character thumb instead

Latest revision as of 20:31, 20 July 2024

How Not To Get Banned[edit]

First: Set a HTTP_USER_AGENT for the tool you will be accessing ACDB from.[edit]

If Python,Perl,etc is in your user agent, you will get errors like

( 402 Payment Required ) 

If you leave it with the default, you will be joining a pool of people who also left it default, and together may pose a DDoS threat. This is why I auto ban curl/python/wget any any other popular tool.

To safely check your user agent, visit this page:

https://www.animecharactersdatabase.com/vars.php

Second: Rate limit your requests.[edit]

Respectfully, limit your bot to 1 request per second.

Current API tools[edit]

Current API Tools

Characters[edit]

Characters API

Titles[edit]

Titles API

Assignments[edit]

Assignments API

License[edit]

Open Database License - Terms of Legal Use

Changes[edit]

January 20th 2021

When requesting birthdays

  • character_image now returns the full sized character image
  • character_thumb has been added to return the character thumb instead