Danbooru
Login Posts Comments Notes Artists Tags Pools Wiki Forum More ยป
Search Changes Help | Posts (0) History
  • Help
guro
scat
furry -rating:g

Recent Changes (all)

  • wuerhosaurus
  • lagoon
  • toriko no shirabe -refrain- chouritsu sareru otome-tachi to onna kyoushi
  • vine whip
  • prisoner invincible
  • toriko no shirabe -refrain- if
  • riding crop
  • approve please genie (vocaloid)
  • long haired invincible
  • flaxan invincible
  • mechanical tentacles
  • miraclesonic expassion (idolmaster)
  • maruzensky (umamusume)
  • golden axe ii
  • neo universe (umamusume)
  • stay gold clan (umamusume)
  • chatsufusa
  • nakayama festa (umamusume)
  • fenomeno (umamusume)
  • no panties
  • window box
  • guile
  • stay gold (umamusume)
  • no bra
  • orfevre (umamusume)

Options

  • Wiki History
  • Discussions
  • What Links Here

api:favorite groups

Table of Contents
  • 01. Record field format
  • 02. Associated attributes
  • 03. Index
  • 04. Show
  • 05. Create
  • 06. Update
  • 07. Add post
  • 08. Remove post
  • 09. Destroy
  • 10. See also
  • 11. External links

This page has details for how to interact with favorite group records through the API.

01 Record field format


NameTypeDetails
idinteger>0
namestring
creator_idinteger>0
post_idsarrayintegers > 0
is_publicboolean
created_attimestamp
updated_attimestamp

02 Associated attributes


The following is the list of relations that can be included in the API results (see Help:Common URL parameters for more info):

NameTypeAvailabilityNumberDetails
creatoruserrequiredsingle

03 Index


Returns multiple favorite group records.

HTTP MethodGET
Base URL/favorite_groups.json
Typeread request
DescriptionThe default order is ID descending.
Search attributes

Search parameters take the following format (see Help:Common URL parameters for more info):

search[FIELD]=VALUE

The following are the base fields along with their associated type. Check the syntax pages for all of the available variations.

  • Number syntax
    • id
    • created_at
    • updated_at
  • Text syntax
    • name
  • User syntax
    • creator
  • Array syntax
    • post_ids
  • Boolean syntax
    • is_public
Special search parameters

The following are additional search fields.

  • name_contains - Normalized case-insensitive wildcard searching on the name text field.
Search order

Using the search parameter order with one of the following values changes the order of the results.

  • name - Alphabetic order by name, then ID descending.
  • created_at - Orders by creation time descending.
  • updated_at - Orders by update time descending, then ID descending.
  • post_count - Orders by post count, then ID descending.

04 Show


Returns a single favorite group record.

HTTP MethodGET
Base URL/favorite_groups/$id.json
Typeread request
Description$id is the favorite group ID.

05 Create


Creates a single favorite group record.

HTTP MethodPOST
Base URL/favorite_groups.json
Typewrite request
Description
Create parameters

Favorite group parameters take the following format (see Help:API Write Requests for more info):

favorite_group[FIELD]=VALUE
  • Required:
    • name
  • Optional:
    • post_ids - Uses URL array parameter format.
    • post_ids_string - Space delimited list of post IDs.
    • is_public - Only Gold+ users can set this to false.

06 Update


HTTP MethodPUT/PATCH
Base URL/favorite_groups/$id.json
Typewrite request
Description$id is the favorite group ID.
Update parameters

Accepts the same parameters create action. All parameters are optional.

07 Add post


Adds a single post to a favorite group.

HTTP MethodPUT
Base URL/favorite_groups/$id/add_post.json
Typewrite request
Description$id is the favorite group ID.
Add post parameters
  • Required:
    • post_id - The post ID to add to the favorite group.

08 Remove post


Removes a single post from a favorite group.

HTTP MethodPUT
Base URL/favorite_groups/$id/remove_post.json
Typewrite request
Description$id is the favorite group ID.
Remove post parameters
  • Required:
    • post_id - The post ID to remove from the favorite group.

09 Destroy


Deletes a single favorite group record.

HTTP MethodDELETE
Base URL/favorite_groups/$id.json
Typewrite request
Description$id is the favorite group ID.

Note: Favorite group records are destroyed rather than deleted and cannot be viewed or retrieved later.

10 See also


  • Help:API
  • Help:Common URL Parameters

11 External links


Controllerhttps://github.com/danbooru/danbooru/blob/master/app/controllers/favorite_groups_controller.rb
Modelhttps://github.com/danbooru/danbooru/blob/master/app/models/favorite_group.rb
Policyhttps://github.com/danbooru/danbooru/blob/master/app/policies/favorite_group_policy.rb
Terms / Privacy / Upgrade / Contact /