Basic FoolFuuka

Return post

Returns the post object

Required parameters

Name /type Description /example Example
board
string
Board shortname
"plebs"
num
number
Number of the post
1
cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/post/?board=plebs&num=1" \
		
Response example
{
  "doc_id": "1",
  "num": "1",
  "subnum": "0",
  "thread_num": "1",
  "op": "1",
  "timestamp": "1366825828",
  "timestamp_expired": "0",
  "capcode": "N",
  "email": null,
  "name": "Anonymous",
  "trip": null,
  "title": null,
  "comment": "4plebs?",
  "poster_hash": null,
  "poster_country": null,
  "sticky": "0",
  "locked": "0",
  "deleted": "0",
  "nreplies": null,
  "nimages": null,
  "fourchan_date": "4\/24\/13(Wed)13:50",
  "comment_sanitized": "4plebs?",
  "comment_processed": "4plebs?",
  "formatted": false,
  "title_processed": null,
  "name_processed": "Anonymous",
  "email_processed": null,
  "trip_processed": null,
  "poster_hash_processed": null,
  "poster_country_name": false,
  "poster_country_name_processed": "",
  "media": {
    "media_id": "1",
    "spoiler": "0",
    "preview_orig": "13668258289537s.jpg",
    "media": "13668215782696.jpg",
    "preview_op": "13668258289537s.jpg",
    "preview_reply": null,
    "preview_w": "209",
    "preview_h": "250",
    "media_filename": "feelcup.jpg",
    "media_w": "645",
    "media_h": "773",
    "media_size": "51338",
    "media_hash": "UGaaniyM723FBlG4b77z\/w==",
    "media_orig": "13668215782696.jpg",
    "exif": "{\u0022FileName\u0022:\u0022d4c564ed648381f49af029c9443de206.jpg\u0022,\u0022FileDateTime\u0022:1366825827,\u0022FileSize\u0022:51338,\u0022FileType\u0022:2,\u0022MimeType\u0022:\u0022image\\\/jpeg\u0022,\u0022SectionsFound\u0022:\u0022\u0022,\u0022COMPUTED\u0022:{\u0022html\u0022:\u0022width=\\\u0022645\\\u0022 height=\\\u0022773\\\u0022\u0022,\u0022Height\u0022:773,\u0022Width\u0022:645,\u0022IsColor\u0022:1}}",
    "total": "2",
    "banned": "0",
    "media_status": "normal",
    "safe_media_hash": "UGaaniyM723FBlG4b77z_w",
    "remote_media_link": null,
    "media_link": "http:\/\/img.4plebs.org\/boards\/plebs\/image\/1366\/82\/13668215782696.jpg",
    "thumb_link": "http:\/\/img.4plebs.org\/boards\/plebs\/thumb\/1366\/82\/13668258289537s.jpg",
    "media_filename_processed": "feelcup.jpg"
  },
  "board": {
    "name": "4plebs discussion",
    "shortname": "plebs"
  }
}

Return thread

Returns the thread object

Required parameters

Name /type Description /example Example
board
string
Board shortname
"plebs"
num
number
Number of the thread
1
cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/thread/?board=plebs&num=1" \
		
Response example
{
  "1": {
    "op": {
      // post object //
    },
    "posts": {
      "1_7": {
        // post object //
      },
      "1_8": {
        // post object //
      }
    }
  }
}

Return board index

Returns the board index

Required parameters

Name /type Description /example Example
board
string
Board shortname
"plebs"
page
number
Page number
1

Optional parameters

Name /type Description /example Example
order
string
Page order by_post|by_thread|ghost
"by_post"
cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/index/?board=plebs&page=1&order=by_post" \
		
Response example
{
  "1148": {
    "omitted": 0,
    "images_omitted": 0,
    "op": {
      // post object //
    },
    "posts": [
      // post objects //
    ]
  },
  "1145": {
    "omitted": 0,
    "images_omitted": 0,
    "op": {
      // post object //
    },
    "posts": [
      // post objects //
    ]
  },
  // ... //
}

Search function

Returns search results. Search API is limited to 5 requests per minute. Other end points aren't limited.

Optional parameters

Name /type Description /example Example
boards
string
Board shortname. Dot delimiter for multiple.
"adv.trv"
email
string
""
username
string
""
tripcode
string
""
capcode
string
Possible values: user|mod|dev|admin.
"user"
subject
string
""
text
string
""
uid
string
""
country
string
""
filename
string
""
image
string
Base64 encoded md5 hash of media file.
""
deleted
string
Possible values: deleted|not-deleted.
"not-deleted"
ghost
string
Possible values: only|none.
"none"
filter
string
Possible values: image|text
"image"
type
string
Possible values sticky|op|posts.
"posts"
start
string
Start date. Format: YYYY-MM-DD.
""
end
string
End date. Format: YYYY-MM-DD.
""
results
string
Results grouped by thread or none. Possible value: thread
""
order
string
Order of posts. Do not specify for desc.
"asc"
cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/search/?boards=adv.trv&capcode=user&deleted=not-deleted&ghost=none&filter=image&type=posts&order=asc" \
		
Response example
{
  "0": {
    "posts": [
      {
        // post object //
      },
      {
        // post object //
      },
       // ... //
    ]
  },
  "meta": {
    "total_found": 3681872,
    "max_results": 5000,
    "search_title": "Searching for posts that has not been deleted and that are not by ghosts and that are only non-OP posts and that do not contain images and that were made by users and in ascending order."
  }
}

4plebs specific

Site information

Returns site information, archives and boards

cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/site/" \
		
Response example
{
  "site": {
    "url": "http:\/\/archive.4plebs.org\/",
    "name": "4plebs",
    "title": "4plebs",
    "notices": null,
    "media_http": ["http:\/\/img.4plebs.org\/boards"],
    "media_https": ["https:\/\/img.4plebs.org\/boards"],
    "global_search_enabled": true
  },
  "archives": {
    "10": {
      "name": "Advice",
      "shortname": "adv",
      "board_url": "http:\/\/archive.4plebs.org\/adv\/",
      "threads_per_page": "10",
      "original_board_url": "http:\/\/boards.4chan.org\/adv\/",
      "thumbs_url": "",
      "images_url": "",
      "anonymous_default_name": "Anonymous",
      "max_comment_characters_allowed": "4096",
      "max_comment_lines_allowed": "20",
      "cooldown_new_comment": "10",
      "transparent_spoiler": true,
      "enable_flags": false,
      "display_exif": false,
      "enable_poster_hash": false,
      "disable_ghost": false,
      "is_nsfw": false,
      "hide_thumbnails": false,
      "search_enabled": true,
      "board_hidden": false,
      "archive_full_images": true
    },
    // ... //
  },
  "boards": {
    "1": {
      "name": "4plebs discussion",
      "shortname": "plebs",
      "board_url": "http:\/\/archive.4plebs.org\/plebs\/",
      "threads_per_page": "10",
      "original_board_url": "http:\/\/archive.4plebs.org\/plebs\/",
      "thumbs_url": "",
      "images_url": "",
      "anonymous_default_name": "Anonymous",
      "max_comment_characters_allowed": "4096",
      "max_comment_lines_allowed": "20",
      "cooldown_new_comment": "30",
      "transparent_spoiler": true,
      "enable_flags": false,
      "display_exif": false,
      "enable_poster_hash": false,
      "disable_ghost": false,
      "is_nsfw": false,
      "hide_thumbnails": false,
      "search_enabled": false,
      "board_hidden": false,
      "internal_board_settings": {
        "op_image_upload_necessity": "always",
        "thumbnail_op_width": "250",
        "thumbnail_op_height": "250",
        "thumbnail_reply_width": "125",
        "thumbnail_reply_height": "125",
        "max_image_size_kilobytes": "10240",
        "max_image_size_width": "11000",
        "max_image_size_height": "11000",
        "max_posts_count": "400",
        "max_images_count": "250",
        "cooldown_new_thread": "300",
        "thread_lifetime": "1728000",
        "min_image_repost_time": "1"
      }
    }
  }
}

Archives information

Returns site information and archives

cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/archives/" \
		
Response example
{
  "site": {
    "url": "http:\/\/archive.4plebs.org\/",
    "name": "4plebs",
    "title": "4plebs",
    "notices": null,
    "media_http": ["http:\/\/img.4plebs.org\/boards"],
    "media_https": ["https:\/\/img.4plebs.org\/boards"],
    "global_search_enabled": true
  },
  "archives": {
    "10": {
      "name": "Advice",
      "shortname": "adv",
      "board_url": "http:\/\/archive.4plebs.org\/adv\/",
      "threads_per_page": "10",
      "original_board_url": "http:\/\/boards.4chan.org\/adv\/",
      "thumbs_url": "",
      "images_url": "",
      "anonymous_default_name": "Anonymous",
      "max_comment_characters_allowed": "4096",
      "max_comment_lines_allowed": "20",
      "cooldown_new_comment": "10",
      "transparent_spoiler": true,
      "enable_flags": false,
      "display_exif": false,
      "enable_poster_hash": false,
      "disable_ghost": false,
      "is_nsfw": false,
      "hide_thumbnails": false,
      "search_enabled": true,
      "board_hidden": false,
      "archive_full_images": true
    },
    // ... //
  }
}

Boards information

Returns site information and boards

cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/boards/" \
		
Response example
{
  "site": {
    "url": "http:\/\/archive.4plebs.org\/",
    "name": "4plebs",
    "title": "4plebs",
    "notices": null,
    "media_http": ["http:\/\/img.4plebs.org\/boards"],
    "media_https": ["https:\/\/img.4plebs.org\/boards"],
    "global_search_enabled": true
  },
  "boards": {
    "1": {
      "name": "4plebs discussion",
      "shortname": "plebs",
      "board_url": "http:\/\/archive.4plebs.org\/plebs\/",
      "threads_per_page": "10",
      "original_board_url": "http:\/\/archive.4plebs.org\/plebs\/",
      "thumbs_url": "",
      "images_url": "",
      "anonymous_default_name": "Anonymous",
      "max_comment_characters_allowed": "4096",
      "max_comment_lines_allowed": "20",
      "cooldown_new_comment": "30",
      "transparent_spoiler": true,
      "enable_flags": false,
      "display_exif": false,
      "enable_poster_hash": false,
      "disable_ghost": false,
      "is_nsfw": false,
      "hide_thumbnails": false,
      "search_enabled": false,
      "board_hidden": false,
      "internal_board_settings": {
        "op_image_upload_necessity": "always",
        "thumbnail_op_width": "250",
        "thumbnail_op_height": "250",
        "thumbnail_reply_width": "125",
        "thumbnail_reply_height": "125",
        "max_image_size_kilobytes": "10240",
        "max_image_size_width": "11000",
        "max_image_size_height": "11000",
        "max_posts_count": "400",
        "max_images_count": "250",
        "cooldown_new_thread": "300",
        "thread_lifetime": "1728000",
        "min_image_repost_time": "1"
      }
    }
  }
}

Gallery

Returns gallery of a board (100 latest threads)

Required parameters

Name /type Description /example Example
board
string
Board shortname
"plebs"
page
number
Page number
1
cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/gallery/?board=plebs&page=1" \
		
Response example
[
  {
    // post object //
  }, {
    // post object //
  }
]

Intel Share

Returns globally banned media hashes

Required parameters

Name /type Description /example Example
page
number
Page number
1
cURL example
curl -X GET "http://archive.4plebs.org/_/api/chan/intel/?page=1" \
		
Response example
{
  "banned_hashes": [
    "\/\/8lBubUDXXu8XPzr\/GB1Q==",
    "\/4h1xkGAwghktHzaxvBHFg==",
    "\/4p9mjR58I3FtJGa2wkUkQ==",
    // ... //
  ],
  "total_count": "745"
}

Offsite Report

Used for POSTing reports

Required parameters

Name /type Description /example Example
access_key
string
Access key given by the admins
"3d86f29c97c98aaca59fd538f19bb532"
board
string
Board shortname
"plebs"
num
number
Number of the post
1

Optional parameters

Name /type Description /example Example
reason
string
Reason of the report
"report reason"
ip
string
IP of the reporting client. If not set the calling IP will be used.
"10.10.10.10"
cURL example
curl -X POST "http://archive.4plebs.org/_/api/chan/offsite_report/" \
		     --data '{"access_key":"3d86f29c97c98aaca59fd538f19bb532","board":"plebs","num":1,"reason":"report reason","ip":"10.10.10.10"}'
Response example
{"success":"You have successfully submitted a report for this post."}