diff options
Diffstat (limited to 'docs/api/safebooru-dapi-help.html')
| -rw-r--r-- | docs/api/safebooru-dapi-help.html | 159 |
1 files changed, 159 insertions, 0 deletions
diff --git a/docs/api/safebooru-dapi-help.html b/docs/api/safebooru-dapi-help.html new file mode 100644 index 0000000..bf4554e --- /dev/null +++ b/docs/api/safebooru-dapi-help.html @@ -0,0 +1,159 @@ +<!DOCTYPE html> +<html xmlns="//www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + + <meta http-equiv="X-UA-Compatible" content="IE=edge" /> + <meta http-equiv="content-type" content="text/html; charset=utf-8" /> + <meta charset="utf-8" /> + + + <link rel="stylesheet" type="text/css" media="screen" href="https://safebooru.org/css/desktop.css?11" title="default" /> + <script nomodule src="/script/core-js.js" type="9d9bf39ecaab45d83c1b0138-text/javascript"></script> +<script src="https://safebooru.org/script/application.js?2" type="9d9bf39ecaab45d83c1b0138-text/javascript"></script> +<script src="/script/awesomplete.min.js?v2" type="9d9bf39ecaab45d83c1b0138-text/javascript"></script> + + +<script type="9d9bf39ecaab45d83c1b0138-text/javascript"> + window.captchaSiteKey = "0x4AAAAAAAiCWNfyi_ucjsab"; + window.captchaCSSClass = "cf-turnstile"; + window.captchaProvider = "turnstile"; + window.captchaInstance = "tst1"; + window.captchaInstanceFormKey = "captchaKey"; + window.captchaResponseFormKey = "cf-turnstile-response"; + window.captchaRenderIdFn = (id) => '#' + id; + window.getCaptcha = function() { + if (window["turnstile"]) { + return turnstile; + } else { + return undefined; + } + } + + window.captchaScriptLoaded = false; + window.loadCaptchaScript = function() { + if (window.captchaScriptLoaded) return; + window.captchaScriptLoaded = true; + const script = document.createElement('script'); + script.src = "https://challenges.cloudflare.com/turnstile/v0/api.js?onload=loadedCaptchaScript"; + document.body.appendChild(script); + + return new Promise((res, rej) => { + window.loadedCaptchaScript = () => { + console.log("loaded"); + res(); + } + script.onerror = function () { + rej(); + } + }); + } +</script> + + <link rel="shortcut icon" href="favicon.ico" /> + <meta name="theme-color" content="#ffffff"> + <title>Safebooru </title> + + + <meta name="keywords" content="Safebooru, imageboard, anime, search engine, anime search engine, anime imageboard" /> + <meta name="description" content="Safebooru is a anime and manga picture search engine, images are being updated hourly."> + + <meta name="rating" content="general" /> + + <link rel="search" type="application/opensearchdescription+xml" title="safebooru: Coded by Geltas" href="openSearchDesc.xml" /> + + + + +</head> +<body id="body"> +<script src="/script/fluidplayer/fluidplayer.min.js?2" type="9d9bf39ecaab45d83c1b0138-text/javascript"></script> + + <div id="header"> + + <input type="radio" class="tradio" id="rmainmenu" name="navtrigs" /> + <input type="radio" class="tradio" id="rnomenu1" name="navtrigs" checked /> + <input type="radio" class="tradio" id="rsubmenu" name="navtrigs" /> + <input type="radio" class="tradio" id="rnomenu2" name="navtrigs" /> + <label for="rmainmenu" class="tlabel tfirst" id="rlmainmenu"></label> + <label for="rnomenu1" class="tlabel tnomenu tfirst" id="rlnomenu1"></label> + <label for="rsubmenu" class="tlabel tsecond" id="rlsubmenu"></label> + <label for="rnomenu2" class="tlabel tnomenu tsecond" id="rlnomenu2"></label> + + <h2 id="site-title"> + <a href="https://safebooru.org/">Safebooru</a> + + </h2> + <ul class="flat-list" id="navbar"> + <li><a href="https://safebooru.org/index.php?page=account&s=home">My Account</a></li> + <li><a href="https://safebooru.org/index.php?page=post&s=list&tags=all">Posts</a></li> + <li><a href="https://safebooru.org/index.php?page=comment&s=list">Comments</a></li> + <li><a href="https://safebooru.org/index.php?page=wiki&s=list">Wiki</a></li> + <li><a href="https://safebooru.org/index.php?page=alias&s=list">Aliases</a></li> + <li><a href="https://safebooru.org/index.php?page=artist&s=list">Artists</a></li> + <li><a href="https://safebooru.org/index.php?page=tags&s=list">Tags</a></li> + <li><a href="https://safebooru.org/index.php?page=pool&s=list">Pools</a></li> + <li><a href="https://safebooru.org/index.php?page=forum&s=list">Forum</a></li> + <li><a href="https://safebooru.org/index.php?page=stats">Stats</a></li> + <li class="current-page"><a href="https://safebooru.org/index.php?page=help">Help</a></li> + <li><a href="https://twitter.com/safebooru/"> Twitter</a></li> + <li><a href="https://patreon.com/booru" target="_blank"><img src="//safebooru.org/images/p.png"> Patreon</a></li> + + <script type="9d9bf39ecaab45d83c1b0138-text/javascript"> + function desktop_layout() { + document.cookie = "experiment-mobile-layout=false; expires=Fri, 31 Dec 9999 23:59:59 GMT"; + location.reload(); + } + + function mobile_layout() { + document.cookie = "experiment-mobile-layout=; expires=Thu, 01 Jan 1970 00:00:00 GMT"; + location.reload(); + } + </script> + + </ul> +</div><div id="long-notice"></div><div id="notice" class="notice" style="display: none;"></div><div class="has-mail" id="has-mail-notice" style="display: none;"><a href="https://safebooru.org/index.php?page=gmail">You have mail</a></div> +<div id="content"> + <div class="help"> + <h1>API Basics</h1> + You should never receive an error unless the server is overloaded or the search dies. In cases of the searcher breaking, you will receive a response success of "false" and a message stating "search down" or similiar.<br /><br /> + <div class="section"> + <h2>Posts</h2> + <h4>List</h4> +Url for API access: <b>index.php?page=dapi&s=post&q=index</b><br /><br /> +<ul> + <li><strong>limit</strong> How many posts you want to retrieve. There is a hard limit of 1000 posts per request.</li> + <li><strong>pid</strong> The page number.</li> + <li><strong>tags</strong> The tags to search for. Any tag combination that works on the web site will work here. This includes all the meta-tags. See cheatsheet for more information.</li> + <li><strong>cid</strong> Change ID of the post. This is in Unix time so there are likely others with the same value if updated at the same time.</li> + <li><strong>id</strong> The post id.</li> + <li><strong>json</strong> Set to 1 for JSON formatted response.</li> +</ul> + + <h4>Deleted Images</h4> +Url for API access: <b>index.php?page=dapi&s=post&q=index&deleted=show</b><br /><br /> +<ul> + <li><strong>last_id</strong> A numerical value. Will return everything above this number.</li> +</ul> +</div> + <div class="section"> + <h2>Comments</h2> + <h4>List</h4> +Url for API access: <b>ndex.php?page=dapi&s=comment&q=index</b><br /><br /> +<ul> + <li><strong>post_id</strong> The id number of the comment to retrieve.</li> +</ul> + +</div> + + <div class="section"> + <h2>Tags</h2> + <h4>List</h4> +Url for API access: <strong>index.php?page=dapi&s=tag&q=index</strong><br /> +<br /> +<ul> + <li><strong>id</strong> The tag's id in the database. This is useful to grab a specific tag if you already know this value.</li> + <li><strong>limit</strong> How many tags you want to retrieve. There is a default limit of 100 per request.<br> + </li> + </ul> + +</div><script src="/cdn-cgi/scripts/7d0fa10a/cloudflare-static/rocket-loader.min.js" data-cf-settings="9d9bf39ecaab45d83c1b0138-|49" defer></script>
\ No newline at end of file |