{"openapi":"3.1.0","info":{"title":"FML API","version":"2.0","description":"The FML API: published stories, their comments, members. Documentation: https://apps.fmylife.com/docs\n\nError codes (`error`: \"code - message\"):\n\n- 1 ERR_ARTICLE_NOT_PROVIDED: No article provided.\n\n- 2 ERR_ARTICLE_NOT_FOUND: Article not found.\n\n- 3 ERR_ARTICLE_CONTENT_MISSING: No article content provided.\n\n- 4 ERR_ARTICLE_CONTENT_TOOSHORT: Article content must be between 20 and 300 characters long.\n\n- 5 ERR_COMMENT_NOT_PROVIDED: No comment content provided.\n\n- 6 ERR_COMMENT_NOT_FOUND: Comment not found.\n\n- 7 ERR_COMMENT_CONTENT_MISSING: No comment content provided.\n\n- 8 ERR_COMMENT_CONTENT_INVALID: Comment content must be between 20 and 300 characters long.\n\n- 9 ERR_MISSING_PARAM: Missing parameter\n\n- 10 ERR_USER_NOT_FOUND: This user not found.\n\n- 11 ERR_USER_USERNAME_ALREADY_EXIT: This username is already associated with an account.\n\n- 12 ERR_USER_EMAIL_ALREADY_EXIT: This email is already associated with an account.\n\n- 13 ERR_USER_EMAIL_INVALID: This email is not valid.\n\n- 14 ERR_USER_ABOUT_ME_INVALID: About me content can not exceed more 300 characters long.\n\n- 15 ERR_USER_IMAGE_IS_TO_LARGE: The file is too large. Allowed maximum size is 1 MB.\n\n- 16 ERR_USER_MISSING_CONFIRM_PASSWORD_FIELD: Field confirm_password is missing.\n\n- 17 ERR_USER_PASSWORD_FIELDS_MUST_MATCH: The password fields must match.\n\n- 18 ERR_USER_ALREADY_LIKED: You have already liked this user.\n\n- 21 ERR_ARTICLE_EMAIL_REQUIRED: You need to provide an email address\n\n- 23 ERR_ARTICLE_ALREADY_VOTED: Article already voted\n\n- 25 ERR_SUPPORT_INVALID_SUBJECT: Invalid subject provided\n\n- 26 ERR_SUPPORT_INVALID_MESSAGE: Invalid message provided\n\n- 27 ERR_MEDIA_IMAGE_NOT_FOUND: Image not found.\n\n- 28 ERR_BADGE_NOT_FOUND: Badge not found.\n\n- 29 ERR_VOTETYPE_INVALID: Provided vote type is invalid\n\n- 30 ERR_TWITTER_INVALID_INFOS: Missing datas for twitter connect\n\n- 31 ERR_TIMELINE_ALREADY_LIKED: User already liked this post\n\n- 32 ERR_USER_ACCOUNT_IS_BANNED: User account is banned\n\n- 33 ERR_USER_NOT_COMMENT_OWNER: User does not own comment\n\n- 34 ERR_USER_ACCOUNT_NOT_VALIDATED: You need to validate your account, check your emails.\n\n- 35 ERR_FACEBOOK_INVALID_INFOS: Missing datas for facebook connect\n\n- 99 ERR_UNKNOWN: Unknown error\n\n- 100 ERR_UNAUTHORIZED: You must be authenticated in order to access this function.\n\n- 102 ERR_INVALID_KEY: Invalid API key.\n\n- 103 ERR_INVALID_LOGIN: Invalid login credentials.\n\n- 104 ERR_INVALID_TOKEN: Invalid or expired API token."},"externalDocs":{"url":"https://apps.fmylife.com/docs"},"servers":[{"url":"https://www.fmylife.com/api/v2"}],"tags":[{"name":"general","description":"General"},{"name":"users","description":"Members"},{"name":"articles","description":"Stories"},{"name":"comments","description":"Comments"},{"name":"badges","description":"Badges"}],"paths":{"/":{"get":{"operationId":"api_infos","tags":["general"],"summary":"Get API information","description":"Use it to check that the API is up and that your API key is accepted. Returns `version`, `apikey` and `userid`: the authenticated member's id, else the `X-VDM-Uniqid` value, else `unknown`.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"version":"2.0","apikey":"{{apikey}}","userid":"1237346633","meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/appconfig":{"get":{"operationId":"api_appconfig","tags":["general"],"summary":"Get the app configuration","description":"Returns a configuration object under `data`, cacheable for 24 hours. It currently holds at most a `contest` boolean (whether a story contest is running) and may be empty.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[],"meta":{},"badge":[],"badge_display":[]}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/support":{"post":{"operationId":"api_support","tags":["general"],"summary":"Send a message to support","description":"When authenticated, the member's username and email are used as the sender. Otherwise, `username` must be a valid email address. The subject is prefixed with your API key's description. Returns 202 on success, 400 if the email, subject or message is missing or invalid.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"username":{"type":"string","description":"string, POST — sender's email address (required when not authenticated, ignored otherwise)"},"subject":{"type":"string","description":"string, POST, required — message subject"},"message":{"type":"string","description":"string, POST, required — message body"}}}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"username":{"type":"string","description":"string, POST — sender's email address (required when not authenticated, ignored otherwise)"},"subject":{"type":"string","description":"string, POST, required — message subject"},"message":{"type":"string","description":"string, POST, required — message body"}}}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":null,"meta":{},"badge":[],"badge_display":[]}}}},"400":{"description":"Error","content":{"application/json":{"example":"{\n  \"data\": [\n    \"Invalid message provided\"\n  ],\n  \"meta\": {}\n}\n----\n{\n  \"data\": [\n    \"Invalid subject provided\"\n  ],\n  \"meta\": {}\n}\n----\n{\n  \"data\": [\n    \"Invalid message provided\"\n  ],\n  \"meta\": {}\n}"}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/discover/{service}":{"get":{"operationId":"api_discover","tags":["general"],"summary":"Discover member profiles","description":"Returns active members with a profile picture, created within the last `created` months, paginated (`meta`). The authenticated member is excluded. Without a service (`/discover`) and with `favorite`, `birthday` and `random`, a user token is required (401 otherwise); `lastprofiles`, `lastpictures`, `lastbirthdays` and `followed` also work anonymously. `lat`/`long` only apply when authenticated, and this location filter currently returns a server error. Example: `/discover/lastprofiles?gender=woman&relation[]=single&agemin=19&agemax=50&page[number]=1&page[bypage]=10`.","parameters":[{"name":"service","in":"path","required":true,"schema":{"type":"string","enum":["favorite","birthday","lastprofiles","lastpictures","lastbirthdays","random","followed"]}},{"name":"service","in":"query","description":"string, optional, in the path — `favorite` (random order for now), `birthday` (members born on the same date as you), `lastprofiles` (newest members first), `lastpictures` (latest profile pictures first), `lastbirthdays` (members whose birthday is today), `random` (random order) or `followed` (most followed first). Without a service: newest members first","schema":{"type":"string"}},{"name":"lat","in":"query","description":"float or `auto`, optional — latitude of the search area's center (about ±0.66°); `auto` uses your home city. Use with `long`","schema":{"type":"string"}},{"name":"long","in":"query","description":"float or `auto`, optional — longitude of the search area's center (about ±0.66°); `auto` uses your home city. Use with `lat`","schema":{"type":"string"}},{"name":"gender","in":"query","description":"`man` or `woman`, optional — gender of the profiles, based on their title","schema":{"type":"string"}},{"name":"relation","in":"query","description":"array of strings, optional — relationship statuses to include: `single`, `couple`, `complicated` (e.g. `relation[]=single&relation[]=couple`)","schema":{"type":"string"}},{"name":"agemin","in":"query","description":"integer, optional — minimum age","schema":{"type":"string"}},{"name":"agemax","in":"query","description":"integer, optional — maximum age","schema":{"type":"string"}},{"name":"created","in":"query","description":"integer, default 24 — only profiles created within this many months","schema":{"type":"string"}},{"name":"random","in":"query","description":"boolean, default false — return the results in random order; any non-empty value other than `0` turns it on","schema":{"type":"string"}},{"name":"page","in":"query","description":"array — pagination: `page[number]` (page number, default 1) and `page[bypage]` (items per page, default 30)","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[],"meta":{"page":1,"per_page":2,"page_count":0,"total_count":0},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/keyword":{"get":{"operationId":"api_keyword_empty","tags":["general"],"summary":"List category keywords","description":"Returns the current site's keywords used as categories, sorted by name. To search all keywords by prefix, use `/keyword/{expr}`.","parameters":[{"name":"expr","in":"query","description":"Not used on this route: to filter by prefix, use `/keyword/{expr}`","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":"20","uid":20,"name":"Animals","label":"Animals","rub":true},{"id":"25","uid":25,"name":"Geek","label":"Geek","rub":true}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/keyword/{expr}":{"get":{"operationId":"api_keyword","tags":["general"],"summary":"Search keywords by prefix","description":"Returns the current site's keywords whose name starts with `{expr}`, sorted by name. Unlike `/keyword`, the results aren't limited to categories.","parameters":[{"name":"expr","in":"path","required":true,"schema":{"type":"string"}},{"name":"expr","in":"query","description":"string, in the path (`{expr}`) — beginning of the keyword name","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/authenticate":{"post":{"operationId":"api_authenticate","tags":["users"],"summary":"Log a member in","description":"On success, returns the member object (200) and the user token in the `X-VDM-Api-Token` response header: send that header with your next requests. Returns 401 if the credentials are missing or wrong, or if the account is banned.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"login":{"type":"string","description":"string, required — username or email address"},"password":{"type":"string","description":"string, required — the member's password, in plain text (always use HTTPS)"}},"required":["login","password"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"login":{"type":"string","description":"string, required — username or email address"},"password":{"type":"string","description":"string, required — the member's password, in plain text (always use HTTPS)"}},"required":["login","password"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"id":1079692805,"fbid":0,"twid":0,"dateEntry":"2026-10-30T08:55:02+01:00","dateUpdate":"2026-10-30T08:55:02+01:00","status":0,"role":["ROLE_USER"],"username":"DocsTester","email":"name@example.com","city":"Paris","area":null,"country":null,"timezone":null,"birthday":null,"origin":0,"bio":null,"source":"site","relation":null,"title":null,"site":2,"oldIDVDM":null,"oldIDFML":null,"avatar":null,"metrics":null,"signature":null},"meta":{},"badge":[],"badge_display":[]}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"100 - You must be authenticated in order to access this function."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"103 - Invalid login credentials."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/refreshtoken":{"post":{"operationId":"api_refreshtoken","tags":["users"],"summary":"Refresh a user token","description":"Send the expired token in the `X-VDM-Api-Token` header along with `secret`. The old token is deleted; the new one comes back in the `X-VDM-Api-Token` response header, with the member object (200). Returns 401 on failure.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"secret":{"type":"string","description":"string, required — the member's secret: MD5 hash of the member id followed by the username (`md5(id . username)`)"}},"required":["secret"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"secret":{"type":"string","description":"string, required — the member's secret: MD5 hash of the member id followed by the username (`md5(id . username)`)"}},"required":["secret"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"id":2321654987,"fbid":0,"twid":0,"dateEntry":"2016-09-16 08:00:18","dateUpdate":"2016-09-16 08:00:18","status":1,"role":{"0":"ROLE_ADMIN"},"username":"admin","email":"fred@free.fr","city":null,"area":null,"country":null,"timezone":"Africa/Harare","birthday":"1997-11-23","origin":1,"bio":"Reiciendis sint sunt eum id tempora rerum occaecati corrupti.","source":"cowroker","relation":"couple","title":"mr","site":1},"meta":{}}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/logout":{"get":{"operationId":"api_logout","tags":["users"],"summary":"Log the member out","description":"Deletes the user token sent in `X-VDM-Api-Token`. Returns `anonymous` on success, 401 if the token is invalid.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":"anonymous","meta":{}}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"100 - You must be authenticated in order to access this function."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/search":{"get":{"operationId":"api_user_search","tags":["users"],"summary":"Check whether a username or email is available","description":"Returns `{\"isValid\": true}` when no account uses the value, else `isValid: false` with an `error` message. For an email, the domain is checked too. Returns 400 if `search` or `value` is missing or invalid.","parameters":[{"name":"search","in":"query","required":true,"description":"string, required — field to check: `username` or `email`","schema":{"type":"string"}},{"name":"value","in":"query","required":true,"description":"string, required — the username or email address to check","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"isValid":true},"meta":{},"badge":[],"badge_display":[]}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"This username is already associated with an account."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/options":{"get":{"operationId":"api_user_options","tags":["users"],"summary":"Get a member's options","description":"Returns the member's notification, newsletter and privacy options, as set with `/user/{userid}/moreinfos`. Requires a user token.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — member id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"user_id":1079692805,"nl_weekly":true,"nl_monthly":false,"nl_daily":false,"al_comment":false,"al_message":false,"hide_profile":false,"show_activity":true,"show_receipt":true,"optin_vdm":true,"optin_partners":true,"activity_on_timeline":true,"hide_illustrations":false,"user_content_types_filters":[]},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user":{"post":{"operationId":"api_user_create","tags":["users"],"summary":"Create an account","description":"Returns the new member (201) and logs them in: the user token is in the `X-VDM-Api-Token` response header. Avatar image files can be sent in the same multipart request. Returns 400 if the username or email is already taken, the email is invalid, or the passwords don't match.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"username":{"type":"string","description":"string, required — username"},"email":{"type":"string","description":"string, required — email address"},"password":{"type":"string","description":"string, required — password"},"confirm_password":{"type":"string","description":"string, required — the same password again"}},"required":["username","email","password","confirm_password"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"username":{"type":"string","description":"string, required — username"},"email":{"type":"string","description":"string, required — email address"},"password":{"type":"string","description":"string, required — password"},"confirm_password":{"type":"string","description":"string, required — the same password again"}},"required":["username","email","password","confirm_password"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"id":50467299,"fbid":0,"twid":0,"dateEntry":{"date":"2016-09-16 10:28:19.000000","timezone_type":3,"timezone":"UTC"},"dateUpdate":null,"status":0,"role":{"0":"ROLE_USER"},"username":"test","email":"test@test.com","city":null,"area":null,"country":null,"timezone":null,"birthday":null,"origin":"api","bio":null,"source":"site","relation":null,"title":"mr","site":3},"meta":{}}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"This username is already associated with an account."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/avatar":{"post":{"operationId":"api_user_update_avatar","tags":["users"],"summary":"Upload a member's avatars","description":"Send the images as multipart files. Maximum size: 25 MB per file. Returns the avatars (202). Only for your own account (admins can act on any account), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"img_1":{"type":"string","description":"file, required — first avatar (main profile picture)"},"img_2":{"type":"string","description":"file, optional — second avatar"},"img_3":{"type":"string","description":"file, optional — third avatar"}},"required":["userid","img_1"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"img_1":{"type":"string","description":"file, required — first avatar (main profile picture)"},"img_2":{"type":"string","description":"file, optional — second avatar"},"img_3":{"type":"string","description":"file, optional — third avatar"}},"required":["userid","img_1"]}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"img_1":{"url":"/img/4a081d3b5c2a14e9f38471d80202df34.jpeg/avatar_small/img_users","id":5,"name":"4a081d3b5c2a14e9f38471d80202df34.jpeg"},"img_2":{"url":"/images/default-avatar.jpg","id":""},"img_3":{"url":"/images/default-avatar.jpg","id":""}},"meta":{}}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"400 - The file is too large. Allowed maximum size is 1 MB."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"404 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/moreinfos":{"put":{"operationId":"api_user_update_moreinfos","tags":["users"],"summary":"Update a member's notification and privacy options","description":"Only the fields you send are changed. Each option takes `1` (on) or `0` (off). Returns the updated options (202). Only for your own account (admins can act on any account), 403 otherwise. Read them back with `/user/{userid}/options`.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"optin_vdm":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — receive news from the site"},"optin_partners":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — receive promotional offers from partners"},"nl_weekly":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — subscribe to the weekly newsletter"},"al_comment":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — get notified when a comment is posted on a story you follow"},"al_message":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — get notified of new private messages"},"nl_daily":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — subscribe to the daily newsletter"},"hide_profile":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — hide my profile"},"show_activity":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — show my activity"},"activity_on_timeline":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — publish my activity on my timeline"},"show_receipt":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — send read receipts"},"user_content_types_filters":{"type":"string","description":"array of integers, optional — content type ids to filter out (see `/article/type/list`); an empty value leaves the current filter unchanged"}},"required":["userid"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"optin_vdm":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — receive news from the site"},"optin_partners":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — receive promotional offers from partners"},"nl_weekly":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — subscribe to the weekly newsletter"},"al_comment":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — get notified when a comment is posted on a story you follow"},"al_message":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — get notified of new private messages"},"nl_daily":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — subscribe to the daily newsletter"},"hide_profile":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — hide my profile"},"show_activity":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — show my activity"},"activity_on_timeline":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — publish my activity on my timeline"},"show_receipt":{"type":"integer","enum":[0,1],"description":"`1` or `0`, optional — send read receipts"},"user_content_types_filters":{"type":"string","description":"array of integers, optional — content type ids to filter out (see `/article/type/list`); an empty value leaves the current filter unchanged"}},"required":["userid"]}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"user_id":1079692805,"nl_weekly":true,"nl_monthly":false,"nl_daily":false,"al_comment":false,"al_message":false,"hide_profile":false,"show_activity":true,"show_receipt":true,"optin_vdm":true,"optin_partners":true,"activity_on_timeline":true,"hide_illustrations":false,"user_content_types_filters":[]},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"404 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}":{"delete":{"operationId":"api_user_delete","tags":["users"],"summary":"Request account deletion","description":"Doesn't delete the account right away: emails the member a link to confirm the deletion. Returns 204. Only for your own account (admins can act on any account), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — your member id","schema":{"type":"string"}}],"responses":{"204":{"description":"Success","content":{"application/json":{"example":{"data":{"response":"The procedure was performed"},"meta":{}}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"404 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/like":{"post":{"operationId":"api_user_like","tags":["users"],"summary":"Like a member","description":"Requires a user token: the liker is always the authenticated member, who can't like themselves (401). Returns the liked member's new like count, `number_of_likes` (202), or 208 if you already liked them. The liked member is notified.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"Ignored: the liker is always the authenticated member"},"user_liked":{"type":"string","description":"integer, required — id of the member to like"}},"required":["userid","user_liked"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"Ignored: the liker is always the authenticated member"},"user_liked":{"type":"string","description":"integer, required — id of the member to like"}},"required":["userid","user_liked"]}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":"{\n  \"data\": {\n    \"number_of_likes\": xx\n  },\n  \"meta\": {}\n}"}}},"208":{"description":"Error","content":{"application/json":{"example":{"error":"208 - You have already liked this user."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/connect/facebook":{"post":{"operationId":"api_user_facebook_connect","tags":["users"],"summary":"Log in with Facebook (disabled)","description":"This endpoint is disabled: it always returns 400. Use `/user/authenticate`.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"string — Facebook user id (ignored: endpoint disabled)"},"name":{"type":"string","description":"string — name (ignored: endpoint disabled)"},"email":{"type":"string","description":"string — email address (ignored: endpoint disabled)"},"gender":{"type":"string","description":"string — gender (ignored: endpoint disabled)"},"birthday":{"type":"string","description":"string — date of birth (ignored: endpoint disabled)"},"location":{"type":"string","description":"string — location (ignored: endpoint disabled)"},"picture":{"type":"string","description":"string — picture URL (ignored: endpoint disabled)"}},"required":["id","name","email"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"string — Facebook user id (ignored: endpoint disabled)"},"name":{"type":"string","description":"string — name (ignored: endpoint disabled)"},"email":{"type":"string","description":"string — email address (ignored: endpoint disabled)"},"gender":{"type":"string","description":"string — gender (ignored: endpoint disabled)"},"birthday":{"type":"string","description":"string — date of birth (ignored: endpoint disabled)"},"location":{"type":"string","description":"string — location (ignored: endpoint disabled)"},"picture":{"type":"string","description":"string — picture URL (ignored: endpoint disabled)"}},"required":["id","name","email"]}}}},"responses":{"200":{"description":"Success"},"400":{"description":"Success","content":{"application/json":{"example":{"data":"Missing datas for facebook connect","meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/connect/twitter":{"post":{"operationId":"api_user_twitter_connect","tags":["users"],"summary":"Log in with Twitter (disabled)","description":"This endpoint is disabled: it always returns 400. Use `/user/authenticate`.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"string — Twitter user id (ignored: endpoint disabled)"},"name":{"type":"string","description":"string — name (ignored: endpoint disabled)"},"email":{"type":"string","description":"string — email address (ignored: endpoint disabled)"},"description":{"type":"string","description":"string — profile description (ignored: endpoint disabled)"},"profile_image_url":{"type":"string","description":"string — picture URL (ignored: endpoint disabled)"}},"required":["id","name","email"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"string — Twitter user id (ignored: endpoint disabled)"},"name":{"type":"string","description":"string — name (ignored: endpoint disabled)"},"email":{"type":"string","description":"string — email address (ignored: endpoint disabled)"},"description":{"type":"string","description":"string — profile description (ignored: endpoint disabled)"},"profile_image_url":{"type":"string","description":"string — picture URL (ignored: endpoint disabled)"}},"required":["id","name","email"]}}}},"responses":{"200":{"description":"Success"},"400":{"description":"Success","content":{"application/json":{"example":{"data":"Missing datas for twitter connect","meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/resetpassword":{"post":{"operationId":"api_user_reset_password","tags":["users"],"summary":"Send a password reset link","description":"If an account uses this email, sends it a link to choose a new password; the current password keeps working until then. Returns 200 for any valid email, whether an account uses it or not, and 400 if the email is invalid.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string","description":"string, required — the account's email address"}},"required":["email"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"email":{"type":"string","description":"string, required — the account's email address"}},"required":["email"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":"User's password has been reset","meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"404 - This user not found."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/edit/password/{userid}":{"put":{"operationId":"api_user_edit_password","tags":["users"],"summary":"Change a member's password","description":"Returns 202 on success, 400 if `confirm_password` is missing or doesn't match, 403 if `current_password` is missing or wrong. The member's other sessions (their other tokens) are signed out; the request's token stays valid. Only for your own account (an admin can act on any account without `current_password`), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"current_password":{"type":"string","description":"string, required — the member's current password"},"password":{"type":"string","description":"string, required — new password"},"confirm_password":{"type":"string","description":"string, required — the new password again"}},"required":["userid","current_password","password","confirm_password"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"current_password":{"type":"string","description":"string, required — the member's current password"},"password":{"type":"string","description":"string, required — new password"},"confirm_password":{"type":"string","description":"string, required — the new password again"}},"required":["userid","current_password","password","confirm_password"]}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":"User's password has been updated","meta":{}}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"16 - Field confirm_password is missing."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/edit/email/{userid}":{"put":{"operationId":"api_user_edit_email","tags":["users"],"summary":"Change a member's email address","description":"The account goes back to pending until the member clicks the confirmation link sent to the new address. Returns 202 on success, 400 if the email is taken or invalid, 403 if `current_password` is missing or wrong. Only for your own account (an admin can act on any account without `current_password`), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"current_password":{"type":"string","description":"string, required — the member's current password"},"email":{"type":"string","description":"string, required — new email address"}},"required":["userid","current_password","email"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"current_password":{"type":"string","description":"string, required — the member's current password"},"email":{"type":"string","description":"string, required — new email address"}},"required":["userid","current_password","email"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":"User's email has been updated","meta":{}}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"12 - This email is already associated with an account."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/uniqid":{"get":{"operationId":"api_user_generate_uniqid","tags":["users"],"summary":"Generate a visitor id","description":"Returns `{\"uniqid\": …}`, a random integer that identifies an anonymous device. Send it in the `X-VDM-Uniqid` header so that votes, smileys and moderation are recorded without an account.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"uniqid":1237550485},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/profile":{"put":{"operationId":"api_user_update_profile","tags":["users"],"summary":"Update a member's profile","description":"Only the fields sent are changed: `title`, `birthday`, `city`, `relation`, `bio`, plus `area`, `country`, `countrycode`, `timezone` and `source`; other fields are ignored (email and password have their own endpoints). Returns the updated member (202), or 400 if the bio is too long. Only for your own account (an admin can act on any account), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"title":{"type":"string","description":"string, optional — title: `mr`, `mrs` or `miss`"},"birthday":{"type":"string","format":"date","description":"date, optional — date of birth, `YYYY-MM-DD` or ISO 8601"},"city":{"type":"string","description":"string, optional — city"},"relation":{"type":"string","description":"string, optional — relationship status: `single`, `couple` or `complicated`"},"bio":{"type":"string","description":"string, optional — biography, up to 2,000 characters"}},"required":["userid"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"title":{"type":"string","description":"string, optional — title: `mr`, `mrs` or `miss`"},"birthday":{"type":"string","format":"date","description":"date, optional — date of birth, `YYYY-MM-DD` or ISO 8601"},"city":{"type":"string","description":"string, optional — city"},"relation":{"type":"string","description":"string, optional — relationship status: `single`, `couple` or `complicated`"},"bio":{"type":"string","description":"string, optional — biography, up to 2,000 characters"}},"required":["userid"]}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"id":1079692805,"fbid":0,"twid":0,"dateEntry":"2026-10-30T08:55:02+01:00","dateUpdate":"2026-10-30T08:55:02+01:00","status":0,"role":["ROLE_USER"],"username":"DocsTester","email":"name@example.com","city":"Paris","area":null,"country":null,"timezone":null,"birthday":null,"origin":0,"bio":null,"source":"site","relation":null,"title":null,"site":2,"oldIDVDM":null,"oldIDFML":null,"avatar":null,"metrics":null,"signature":null},"meta":{},"badge":[],"badge_display":[]}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"14 - About me content can not exceed more 300 characters long."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]},"get":{"operationId":"api_user_profile","tags":["users"],"summary":"Get a member's profile, signed in","description":"Requires a user token. Like `/user/{userid}/member`, plus the number of visits, likes and friends; the visit is counted for the signed-in member. 404 if the member doesn't exist.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, in the path — member id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"user":{"id":1079692805,"fbid":0,"twid":0,"dateEntry":"2026-10-30T08:55:02+01:00","dateUpdate":"2026-10-30T08:55:02+01:00","status":0,"role":["ROLE_USER"],"username":"DocsTester","email":"name@example.com","city":"Paris","area":null,"country":null,"timezone":null,"birthday":null,"origin":0,"bio":null,"source":"site","relation":null,"title":null,"site":2,"oldIDVDM":null,"oldIDFML":null,"avatar":null,"metrics":null,"signature":null},"avatar_1":null,"avatar_2":null,"avatar_3":null,"profile_visibility":false,"number_of_visits":3,"number_of_likes":0,"number_of_friends":0,"number_of_followers":0,"number_of_comment":0,"number_of_favorite":0,"number_of_article":0,"number_of_badge":3,"metrics":{"isFollowed":false,"isBlocked":false,"isLike":false}},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"404 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/member":{"get":{"operationId":"api_user_member","tags":["users"],"summary":"Get a member's public page","description":"Returns the member (public fields, except for yourself and admins), their three avatars, their profile visibility and their metrics. With `X-VDM-Uniqid`, the visit is counted. 404 if the member doesn't exist.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, in the path — member id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"user":{"id":1079692805,"dateEntry":"2026-10-30T08:55:02+01:00","status":0,"username":"DocsTester","city":"Paris","country":null,"bio":null,"relation":null,"title":null,"site":2,"avatar":null,"metrics":null,"signature":null},"avatar_1":null,"avatar_2":null,"avatar_3":null,"profile_visibility":false,"number_of_visits":3,"number_of_likes":0,"number_of_friends":0,"number_of_followers":0,"number_of_comment":0,"number_of_favorite":0,"number_of_article":0,"number_of_badge":3},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"404 - This user not found."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/visits":{"get":{"operationId":"api_user_visits","tags":["users"],"summary":"List a member's profile visitors","description":"Paginated: `meta` gives `page`, `per_page`, `page_count` and `total_count`. Most recent visits first by default.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — member id","schema":{"type":"string"}},{"name":"page","in":"query","description":"array — pagination: `page[number]` (page number, default 1) and `page[bypage]` (items per page, default 30)","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true},{"name":"orderby","in":"query","description":"array, default `orderby[date]=DESC` — sort order, as `orderby[field]=ASC|DESC`","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[],"meta":{"page":1,"per_page":30,"page_count":0,"total_count":0},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/likes":{"get":{"operationId":"api_user_likes","tags":["users"],"summary":"List the members who liked a member","description":"Paginated: `meta` gives `page`, `per_page`, `page_count` and `total_count`. Most recent likes first by default.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — member id","schema":{"type":"string"}},{"name":"page","in":"query","description":"array — pagination: `page[number]` (page number, default 1) and `page[bypage]` (items per page, default 30)","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true},{"name":"orderby","in":"query","description":"array, default `orderby[date]=DESC` — sort order, as `orderby[field]=ASC|DESC`","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[],"meta":{"page":1,"per_page":30,"page_count":0,"total_count":0},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/avatar/{userid}/{imageid}":{"delete":{"operationId":"api_user_delete_avatar","tags":["users"],"summary":"Delete one of a member's avatars","description":"Returns 200 on success, 404 if the member or image doesn't exist. Only for your own account (admins can act on any account), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"imageid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — your member id","schema":{"type":"string"}},{"name":"imageid","in":"query","required":true,"description":"integer, required, in the path (`{imageid}`) — id of the image to delete","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":"{\n  \"data\": \"User's avatar has been deleted\",\n  \"meta\": {}\n}\n\nWith attribute /all\n\n{\n  \"data\": \"All user's avatar has been deleted\",\n  \"meta\": {}\n}"}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/avatar/{userid}/all":{"delete":{"operationId":"api_user_delete_all_avatar","tags":["users"],"summary":"Delete all of a member's avatars","description":"Returns 200 on success. Only for your own account (admins can act on any account), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — your member id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":"All user's avatar has been deleted","meta":{}}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/avatar/{userid}":{"patch":{"operationId":"api_user_patch_avatar","tags":["users"],"summary":"Reorder a member's avatars","description":"Send the image ids in the order you want them displayed. Returns 200. Only for your own account (admins can act on any account), 403 otherwise.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"img_1":{"type":"string","description":"integer, required — id of the image to show first"},"img_2":{"type":"string","description":"integer, required — id of the image to show second"},"img_3":{"type":"string","description":"integer, required — id of the image to show third"}},"required":["userid","img_1","img_2","img_3"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"userid":{"type":"string","description":"integer, required — your member id"},"img_1":{"type":"string","description":"integer, required — id of the image to show first"},"img_2":{"type":"string","description":"integer, required — id of the image to show second"},"img_3":{"type":"string","description":"integer, required — id of the image to show third"}},"required":["userid","img_1","img_2","img_3"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":"User's avatar have been updated","meta":{}}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/badges":{"get":{"operationId":"api_user_get_badges","tags":["users"],"summary":"List a member's badges","description":"Requires a user token. Returns 404 if the member doesn't exist.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — member id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"user":1079692805,"id":31,"status":1,"progression":1,"data":"","stamp":"2026-10-30T08:56:01+01:00","site":null,"name":"Invader","description":"You were outside of France when you submitted this FML","hidden":"0","goal":1,"limited":"0","category":2,"total":58801,"illustration":"31.gif"},{"user":1079692805,"id":17,"status":1,"progression":1,"data":"","stamp":"2026-10-30T08:56:01+01:00","site":null,"name":"Perfectionist","description":"Editing your comments can help you avoid embarrassment, and it might make you seem smarter.","hidden":"0","goal":1,"limited":"0","category":1,"total":33966,"illustration":"17.gif"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/articles":{"get":{"operationId":"api_user_get_articles","tags":["users"],"summary":"List a member's stories","description":"Requires a user token. For your own account, your stories in every status except deleted (including pending and refused ones); for another member, their published stories only. With keywords, metrics, images, paragraphs and videos. Not paginated.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — member id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":518674,"status":11,"type":1,"spicy":false,"optin":false,"socialTruncate":false,"title":null,"content":"Today, I tested the API for an hour before noticing I had swapped my key and my token. FML","content_hidden":"Today, I tested the API for an hour before noticing I had swapped my key and my token. FML","created":"2026-10-30T08:56:41+01:00","updated":"2026-10-30T08:56:41+01:00","published":"2026-10-30T08:56:41+01:00","user":1079692805,"author":"DocsTester","gender":null,"layout":0,"flag":0,"origin":"api","apikey":"{{apikey}}","vote":1,"site":2,"siteorig":null,"slug":"today-i-tested-the-api-for-an-hour-before-noticing-i-had-swapped-my-key-and-my-token-fml","bitly":null,"metrics":{"article":518674,"comment":0,"favorite":0,"reports":1,"mod_positive":0,"mod_negative":0,"votes_up":0,"votes_down":0,"smiley_amusing":0,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"usermetrics":{"favorite":false,"smiley":null,"votes":null},"keywords":[],"images":[],"videos":[],"openview":0,"url":null,"suggested":null,"paragraphs":[]},{"id":518673,"status":0,"type":1,"spicy":false,"optin":false,"socialTruncate":false,"title":null,"content":"Today, I tested the API for an hour before noticing I had swapped my key and my token. FML","content_hidden":"Today, I tested the API for an hour before noticing I had swapped my key and my token. FML","created":"2026-10-30T08:56:01+01:00","updated":"2026-10-30T08:56:09+01:00","published":"2026-10-30T08:56:01+01:00","user":1079692805,"author":"DocsTester","gender":null,"layout":0,"flag":0,"origin":"api","apikey":"{{apikey}}","vote":1,"site":2,"siteorig":null,"slug":"today-i-tested-the-api-for-an-hour-before-noticing-i-had-swapped-my-key-and-my-token-fml","bitly":null,"metrics":{"article":518673,"comment":0,"favorite":0,"reports":1,"mod_positive":0,"mod_negative":0,"votes_up":0,"votes_down":0,"smiley_amusing":0,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"usermetrics":{"favorite":false,"smiley":null,"votes":null},"keywords":[],"images":[],"videos":[],"openview":0,"url":null,"suggested":null,"paragraphs":[]}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/favorites":{"get":{"operationId":"api_user_get_favorites","tags":["users"],"summary":"List a member's favorite stories","description":"Requires a user token. Paginated (`meta`). Each story includes your own votes, smileys and favorite status.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — member id","schema":{"type":"string"}},{"name":"page","in":"query","description":"array — pagination: `page[number]` (page number, default 1) and `page[bypage]` (items per page, default 30)","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[],"meta":{"page":1,"per_page":30,"page_count":0,"total_count":0},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/user/{userid}/comments":{"get":{"operationId":"api_user_get_comments","tags":["users"],"summary":"List a member's comments","description":"Requires a user token. Returns the member's top-level comments (not their replies to other comments), each with its replies. Not paginated.","parameters":[{"name":"userid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"userid","in":"query","required":true,"description":"integer, required — member id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":176,"date":"2026-10-30T08:56:01+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":2,"userthumbed":1,"report":1,"isModerator":false,"replies":null},{"id":177,"date":"2026-10-30T08:56:41+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":0,"userthumbed":0,"report":0,"isModerator":false,"replies":null}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"10 - This user not found."}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/status/list":{"get":{"operationId":"api_article_status_list","tags":["articles"],"summary":"List story statuses","description":"Returns `uid`/`label` pairs: 0 new (awaiting community moderation), 1 rejected, 2 promoted, 3 refused, 4 validated (published), 5 private, 6 autopilot, 7 deleted, 8 scheduled, 9 tocheck, 10 BestOfPire, 11 Check Edito (awaiting editorial review), 12 republished.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"uid":11,"label":"Check Edito"},{"uid":0,"label":"new"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/type/list":{"get":{"operationId":"api_article_type_list","tags":["articles"],"summary":"List story types","description":"Returns `uid`/`label` pairs, for example 1 classic, 3 photo, 6 confession, 9 news, 10 video, 16 contest.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"uid":1,"label":"classic"},{"uid":3,"label":"photo"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":"{\n  \"error\": \"102 - Invalid API key.\"\n}\n\nERROR CODE: 500 (INTERNAL SERVER ERROR)\nContent:\n{\n  \"error\": \"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known\"\n}"}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/gender/list":{"get":{"operationId":"api_article_sexe_list","tags":["articles"],"summary":"List author genders","description":"Returns `uid`/`label` pairs: 1 man, 2 woman, 3 Other, 4 Enby, 5 TransFem, 6 TransMasc. Use the `uid` as `gender` when submitting a story.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"uid":1,"label":"man"},{"uid":2,"label":"woman"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/votetype/list":{"get":{"operationId":"api_article_votetype_list","tags":["articles"],"summary":"List vote types","description":"Returns `uid`/`label` pairs (translated labels) for the vote buttons. Use the `uid` with `/article/{article}/vote/{votetype}`.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"uid":1,"label":"You deserved it"},{"uid":2,"label":"Phew, glad it wasn't me"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":"{\n  \"error\": \"102 - Invalid API key.\"\n}\n\nERROR CODE: 500 (INTERNAL SERVER ERROR)\nContent:\n{\n  \"error\": \"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known\"\n}"}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/category/list":{"get":{"operationId":"api_article_category_list","tags":["articles"],"summary":"List categories","description":"Returns the current site's categories, sorted by name, as `uid`, `label` and `rub` (always true). Use a `uid` as `keyword[]` in `/article/list`.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"uid":20,"label":"Animals","rub":true},{"uid":25,"label":"Geek","rub":true}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/smiley/list":{"get":{"operationId":"api_article_smiley_list","tags":["articles"],"summary":"List smileys","description":"Returns `uid`/`label` pairs: 1 amusing, 2 funny, 3 weird, 4 hilarious. Use the `uid` with `/article/{article}/smile/{smiley}`.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"uid":1,"label":"amusing"},{"uid":2,"label":"funny"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article":{"post":{"operationId":"api_article_create","tags":["articles"],"summary":"Submit a story","description":"The story is created with status 11 (Check Edito): the editorial team reviews it before it goes to moderation or publication. It's linked to the authenticated member, if any. Content must be 20 to 320 characters long; surrounding double quotes are removed. Returns the story (201), or 400 if the content is too short or too long, or if a contest entry has no email. Any other field sent is ignored.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"content":{"type":"string","description":"string, required in practice — the story's text, 20 to 320 characters"},"author":{"type":"string","description":"string, optional — author name displayed with the story"},"email":{"type":"string","description":"string, optional — author's email address; required for a contest entry"},"type":{"type":"string","description":"integer, default 1 (classic) — story type: 1 (classic), 3 (photo), 6 (confession), 15 (medics) or 16 (contest); any other value gives 1"},"spicy":{"type":"string","description":"boolean, default false — the story is spicy (adult content)"},"contest":{"type":"string","description":"boolean, default false — contest entry: sets the type to 16 (contest) and makes `email` required"},"optin":{"type":"string","description":"boolean, default false — opt-in flag"},"title":{"type":"string","description":"string, optional — title"},"gender":{"type":"string","description":"integer, optional — author's gender, see `/article/gender/list`"}}}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"content":{"type":"string","description":"string, required in practice — the story's text, 20 to 320 characters"},"author":{"type":"string","description":"string, optional — author name displayed with the story"},"email":{"type":"string","description":"string, optional — author's email address; required for a contest entry"},"type":{"type":"string","description":"integer, default 1 (classic) — story type: 1 (classic), 3 (photo), 6 (confession), 15 (medics) or 16 (contest); any other value gives 1"},"spicy":{"type":"string","description":"boolean, default false — the story is spicy (adult content)"},"contest":{"type":"string","description":"boolean, default false — contest entry: sets the type to 16 (contest) and makes `email` required"},"optin":{"type":"string","description":"boolean, default false — opt-in flag"},"title":{"type":"string","description":"string, optional — title"},"gender":{"type":"string","description":"integer, optional — author's gender, see `/article/gender/list`"}}}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"example":{"data":{"id":518675,"status":11,"type":1,"spicy":false,"optin":false,"socialTruncate":false,"title":null,"content":"Today, I tested the API for an hour before noticing I had swapped my key and my token. FML","content_hidden":null,"created":"2026-10-30T08:57:33+01:00","updated":"2026-10-30T08:57:33+01:00","published":"2026-10-30T08:57:33+01:00","user":1079692805,"author":"DocsTester","gender":null,"layout":0,"flag":0,"origin":"api","apikey":"{{apikey}}","vote":1,"site":2,"siteorig":null,"slug":"today-i-tested-the-api-for-an-hour-before-noticing-i-had-swapped-my-key-and-my-token-fml","bitly":null,"metrics":{"article":0,"comment":0,"favorite":0,"reports":0,"mod_positive":0,"mod_negative":0,"votes_up":0,"votes_down":0,"smiley_amusing":0,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"usermetrics":{"favorite":false,"smiley":null,"votes":null},"keywords":[],"images":[],"videos":[],"openview":0,"url":null,"suggested":null},"meta":{},"badge":[],"badge_display":[]}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"No article content provided."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"error":"Article not found."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/{article}":{"get":{"operationId":"api_article","tags":["articles"],"summary":"Get a story by id","description":"Includes keywords, metrics, images, videos, paragraphs and up to 10 suggested stories, plus your votes, smileys and favorite status when a user token or `X-VDM-Uniqid` is sent. Paragraphs come in a `paragraphs` array of objects with a `type` and a `content`: `html` (HTML text) or `article` (an embedded story, in the same format as `/article/list`). Promoted and refused stories are returned with type 12 (almost). Returns 404 if the story doesn't exist. Private, deleted or scheduled stories also return 404, except for their author and the site's staff.","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}},{"name":"article","in":"query","description":"integer, in the path — story id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"id":6,"status":4,"type":2,"spicy":true,"optin":false,"socialTruncate":false,"title":"Palpation !","content":"Aujourd'hui, je suis convoqué au commissariat, et je me fais palper à l'entrée. Le policier me touche le ventre et me demande : \"Vous avez quoi sous votre pull ?\" Quand j'ai répondu que c'était juste mon ventre, je ne sais pas lequel de nous a été le plus gêné. VDM","content_hidden":"Aujourd'hui, je suis convoqué au commissariat, et je me fais palper à l'entrée. Le policier me touche le ventre et me demande : \"Vous avez quoi sous votre pull ?\" Quand j'ai répondu que c'était juste mon ventre, je ne sais pas lequel de nous a été le plus gêné. VDM","created":"2026-09-29T20:29:40+02:00","updated":"2026-09-29T20:29:40+02:00","published":"2016-06-12T18:29:40+02:00","user":2321654987,"author":null,"gender":null,"layout":0,"flag":0,"origin":null,"apikey":null,"vote":2,"site":2,"siteorig":null,"slug":"palpation","bitly":null,"metrics":{"article":6,"comment":2,"favorite":0,"reports":0,"mod_positive":0,"mod_negative":0,"votes_up":2,"votes_down":0,"smiley_amusing":2,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"usermetrics":{"favorite":false,"smiley":null,"votes":null},"keywords":[],"images":[{"url":"https://www.fmylife.lan/img/IMG_1.jpg/medium/","usage":8,"name":"IMG_1.jpg","copyright":"copyright VDM","legend":"la legende de l'image","width":0,"height":0}],"videos":[],"openview":0,"url":null,"suggested":[],"paragraphs":[]},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":["FML not found."],"meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: Invalid argument supplied for foreach()"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/{article}/moderate/{mod}":{"get":{"operationId":"api_article_moderate","tags":["articles"],"summary":"Moderate a pending story","description":"Community moderation: `{mod}` is `1` (yes, it's an FML) or `0` (no), default `0`. Only stories with status 0 (new) can be moderated; get them with `/article/list?moderate=1`. Requires a user token or an `X-VDM-Uniqid` header (401 otherwise); one vote per voter and story (406 otherwise). Once enough yes votes are reached the story becomes promoted (2); enough no votes and it's rejected (1). Returns the story's metrics (202).","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}},{"name":"mod","in":"path","required":true,"schema":{"type":"string","enum":["0","1"]}}],"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"article":518673,"comment":0,"favorite":0,"reports":1,"mod_positive":1,"mod_negative":0,"votes_up":0,"votes_down":0,"smiley_amusing":0,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":["FML not found."],"meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/{article}/vote/{votetype}":{"get":{"operationId":"api_article_vote","tags":["articles"],"summary":"Vote for a story","description":"`{votetype}` is optional: without it or with `0`, the vote is an up vote; with an id from `/article/votetype/list`, it's a down vote. A user token or `X-VDM-Uniqid` is required (400 otherwise): one vote per voter, story and vote type (406 otherwise). Send the same request with the `DELETE` method to withdraw a vote. Returns the story's metrics (202).","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}},{"name":"votetype","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"article":6,"comment":2,"favorite":0,"reports":0,"mod_positive":0,"mod_negative":0,"votes_up":3,"votes_down":0,"smiley_amusing":2,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":["FML not found."],"meta":{},"badge":[],"badge_display":[]}}}},"406":{"description":"Error","content":{"application/json":{"example":{"error":"Provided vote type is invalid"}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/{article}/report":{"patch":{"operationId":"api_article_report","tags":["articles"],"summary":"Report a story","description":"A user token or `X-VDM-Uniqid` is required (400 otherwise). One report per voter and story: later calls change nothing. Returns the story's metrics (202), 404 if the story doesn't exist.","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"article":518675,"comment":0,"favorite":0,"reports":1,"mod_positive":0,"mod_negative":0,"votes_up":0,"votes_down":0,"smiley_amusing":0,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"FML not found.","meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/{article}/smile/{smiley}":{"get":{"operationId":"api_article_smile","tags":["articles"],"summary":"React to a story with a smiley","description":"Works with a user token or an `X-VDM-Uniqid` header (401 without either). Smiley ids come from `/article/smiley/list`. One reaction per voter, story and smiley (406 otherwise). Returns the new count for this smiley (202).","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}},{"name":"smiley","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":3,"meta":{},"badge":[],"badge_display":[]}}}},"208":{"description":"Error","content":{"application/json":{"example":{"error":"Article already voted"}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"FML not found.","meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/{article}/bookmark":{"patch":{"operationId":"api_article_bookmark","tags":["articles"],"summary":"Add a story to favorites, or remove it","description":"Toggle: the first call adds the story to the member's favorites, the next one removes it. Requires a user token. Returns 202. List favorites with `/user/{userid}/favorites`.","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"user":1079692805,"article":6,"stamp":null},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"FML not found.","meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/{article}/comments":{"get":{"operationId":"api_article_comments","tags":["articles"],"summary":"List a story's comments","description":"Paginated (`meta`). By default, top-level comments in every status except deleted. Returns an empty list when comments are closed on the story. When authenticated, comments from your blocked contacts are removed and your thumbs are included.","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}},{"name":"status","in":"query","description":"array of integers, optional — comment statuses to include: 0 default, 1 highlighted, 2 nuked, 3 confession, 5 forbidden keywords, 6 auto-nuked; default: all except 4 (deleted)","schema":{"type":"array","items":{"type":"integer"}}},{"name":"author","in":"query","description":"array of integers, optional — only comments by these member ids","schema":{"type":"array","items":{"type":"integer"}}},{"name":"parent","in":"query","description":"array of integers, optional — only replies to these comment ids (e.g. `parent[]=123`)","schema":{"type":"array","items":{"type":"integer"}}},{"name":"reported","in":"query","description":"boolean, default false — only comments reported as abuse beyond the site's threshold","schema":{"type":"boolean"}},{"name":"replies","in":"query","description":"boolean, default false — include each comment's replies in its `replies` property","schema":{"type":"boolean"}},{"name":"flat","in":"query","description":"boolean, default false — return comments and replies together in a single flat list","schema":{"type":"boolean"}},{"name":"page","in":"query","description":"array — pagination: `page[number]` (page number, default 1) and `page[bypage]` (items per page, default 30)","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true},{"name":"orderby","in":"query","description":"array, optional — sort order, as `orderby[field]=ASC|DESC`; no particular order by default","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":176,"date":"2026-10-30T08:56:01+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":2,"userthumbed":0,"report":1,"isModerator":false,"replies":null},{"id":177,"date":"2026-10-30T08:56:41+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":0,"userthumbed":0,"report":0,"isModerator":false,"replies":null}],"meta":{"page":1,"per_page":2,"page_count":1,"total_count":2},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"FML not found.","meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/list":{"get":{"operationId":"api_articles","tags":["articles"],"summary":"List stories","description":"Paginated (`meta`). By default, the current site's published stories (status 4), newest first. Results may be cached for up to an hour. Each story has a `url` to its web page; with a user token or `X-VDM-Uniqid`, your votes, smileys and favorites are included. `type[]=12` on its own returns the “almost” stories (refused ones). Example: `/article/list?status[]=4&type[]=1&page[number]=1&page[bypage]=10&orderby[datePublish]=desc`.","parameters":[{"name":"site","in":"query","description":"Ignored: always the current site","schema":{"type":"integer"}},{"name":"moderate","in":"query","description":"boolean, default false — return the next stories you can moderate (status 0 stories you haven't voted on), see `/article/{article}/moderate/{mod}`","schema":{"type":"boolean"}},{"name":"spicy","in":"query","description":"boolean, default false — only spicy stories","schema":{"type":"boolean"}},{"name":"nospicy","in":"query","description":"boolean, default false — exclude spicy stories","schema":{"type":"boolean"}},{"name":"reported","in":"query","description":"boolean, default false — only stories reported at least once","schema":{"type":"boolean"}},{"name":"user","in":"query","description":"integer, optional — only stories by this member id","schema":{"type":"integer"}},{"name":"country","in":"query","description":"array of strings, optional — only stories from these countries (ISO codes)","schema":{"type":"array","items":{"type":"string"}}},{"name":"type","in":"query","description":"array of integers, optional — only these types, see `/article/type/list`","schema":{"type":"array","items":{"type":"integer"}}},{"name":"status","in":"query","description":"array of integers, default `[4]` (validated) — only these statuses, see `/article/status/list`; statuses 5 (private), 7 (deleted) and 8 (scheduled) are ignored, except for the site's staff","schema":{"type":"array","items":{"type":"integer"}}},{"name":"keyword","in":"query","description":"array of integers, optional — only stories linked to these keyword ids, see `/article/category/list`","schema":{"type":"array","items":{"type":"integer"}}},{"name":"after","in":"query","description":"string `YYYY-MM-DD HH:mm:ss`, optional — only stories published after this date","schema":{"type":"string","format":"date-time"}},{"name":"before","in":"query","description":"Currently ignored by the API (only stories published before this date)","schema":{"type":"string","format":"date-time"}},{"name":"created_after","in":"query","description":"string `YYYY-MM-DD HH:mm:ss`, optional — only stories created after this date","schema":{"type":"string","format":"date-time"}},{"name":"created_before","in":"query","description":"string `YYYY-MM-DD HH:mm:ss`, optional — only stories created before this date","schema":{"type":"string","format":"date-time"}},{"name":"expr","in":"query","description":"string, optional — text to search for in the title and content; a number matches the story id","schema":{"type":"string"}},{"name":"page","in":"query","description":"array — pagination: `page[number]` (page number, default 1) and `page[bypage]` (items per page, default 30)","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true},{"name":"orderby","in":"query","description":"array, default `orderby[datePublish]=DESC` — sort order, as `orderby[field]=ASC|DESC`; only column names are accepted","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":6,"status":4,"type":2,"spicy":true,"optin":false,"socialTruncate":false,"title":"Palpation !","content":"Aujourd'hui, je suis convoqué au commissariat, et je me fais palper à l'entrée. Le policier me touche le ventre et me demande : \"Vous avez quoi sous votre pull ?\" Quand j'ai répondu que c'était juste mon ventre, je ne sais pas lequel de nous a été le plus gêné. VDM","content_hidden":"Aujourd'hui, je suis convoqué au commissariat, et je me fais palper à l'entrée. Le policier me touche le ventre et me demande : \"Vous avez quoi sous votre pull ?\" Quand j'ai répondu que c'était juste mon ventre, je ne sais pas lequel de nous a été le plus gêné. VDM","created":"2026-09-29T20:29:40+02:00","updated":"2026-09-29T20:29:40+02:00","published":"2016-06-12T18:29:40+02:00","user":2321654987,"author":null,"gender":null,"layout":0,"flag":0,"origin":null,"apikey":null,"vote":2,"site":2,"siteorig":null,"slug":"palpation","bitly":null,"metrics":{"article":6,"comment":0,"favorite":1,"reports":0,"mod_positive":0,"mod_negative":0,"votes_up":1,"votes_down":0,"smiley_amusing":1,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"usermetrics":{"favorite":false,"smiley":1,"votes":[0]},"keywords":[],"images":[{"url":"https://www.fmylife.lan/img/IMG_1.jpg/medium/","usage":8,"name":"IMG_1.jpg","copyright":"copyright VDM","legend":"la legende de l'image","width":0,"height":0}],"videos":[],"openview":0,"url":"https://www.fmylife.lan/article/palpation_6.html?modeapp=1","suggested":null,"paragraphs":[]}],"meta":{"page":1,"per_page":2,"page_count":1,"total_count":1},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: Invalid argument supplied for foreach()"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/list/short/{expr}":{"get":{"operationId":"api_article_list_short","tags":["articles"],"summary":"Search stories for autocomplete","description":"Requires a user token. Returns up to 10 published stories matching `{expr}` (in the title or content, or the exact id if it's a number), as `id`/`title` pairs; when a story has no title, the beginning of its content is used.","parameters":[{"name":"expr","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":9,"title":"Aujourd'hui, comme tous l..."},{"id":5,"title":"Il manque le stylo !"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":null,"meta":{"status":"ERROR","msg":"You must be authenticated in order to access this function."},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: Invalid argument supplied for foreach()"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/article/top/{period}":{"get":{"operationId":"api_article_top","tags":["articles"],"summary":"List top stories","description":"Published stories sorted by number of votes (up and down), paginated (`meta`). Use `/article/top` for all time or `/article/top/{period}`. With a user token or `X-VDM-Uniqid`, your votes, smileys and favorites are included.","parameters":[{"name":"period","in":"path","required":true,"schema":{"type":"string","pattern":"^\\w+$"}},{"name":"period","in":"query","description":"string, in the path, default `top` — `top` (all time), `top_day`, `top_week`, `top_month` or `top_year` (stories published in the last day, week, month or year); any other value means all time","schema":{"type":"string"}},{"name":"page","in":"query","description":"array — pagination: `page[number]` (page number, default 1) and `page[bypage]` (items per page, default 30)","schema":{"type":"object","additionalProperties":{"type":["string","integer"]}},"style":"deepObject","explode":true}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":6,"status":4,"type":2,"spicy":true,"optin":false,"socialTruncate":false,"title":"Palpation !","content":"Aujourd'hui, je suis convoqué au commissariat, et je me fais palper à l'entrée. Le policier me touche le ventre et me demande : \"Vous avez quoi sous votre pull ?\" Quand j'ai répondu que c'était juste mon ventre, je ne sais pas lequel de nous a été le plus gêné. VDM","content_hidden":"Aujourd'hui, je suis convoqué au commissariat, et je me fais palper à l'entrée. Le policier me touche le ventre et me demande : \"Vous avez quoi sous votre pull ?\" Quand j'ai répondu que c'était juste mon ventre, je ne sais pas lequel de nous a été le plus gêné. VDM","created":"2026-09-29T20:29:40+02:00","updated":"2026-09-29T20:29:40+02:00","published":"2016-06-12T18:29:40+02:00","user":2321654987,"author":null,"gender":null,"layout":0,"flag":0,"origin":null,"apikey":null,"vote":2,"site":2,"siteorig":null,"slug":"palpation","bitly":null,"metrics":{"article":6,"comment":2,"favorite":1,"reports":0,"mod_positive":0,"mod_negative":0,"votes_up":3,"votes_down":0,"smiley_amusing":3,"smiley_funny":0,"smiley_weird":0,"smiley_hilarious":0},"usermetrics":{"favorite":false,"smiley":1,"votes":[0]},"keywords":[],"images":[{"url":"https://www.fmylife.lan/img/IMG_1.jpg/medium/","usage":8,"name":"IMG_1.jpg","copyright":"copyright VDM","legend":"la legende de l'image","width":0,"height":0}],"videos":[],"openview":0,"url":null,"suggested":null}],"meta":{"page":1,"per_page":30,"page_count":1,"total_count":1},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/comment/{article}":{"post":{"operationId":"api_comment_create","tags":["comments"],"summary":"Comment on a story","description":"Requires a user token. Returns the comment (201), 400 if the content is empty, 404 if the story doesn't exist or if `parent` isn't a comment of this story. If the comment is a reply, the parent comment's author is notified. A member can comment once every 30 seconds. Comments containing forbidden words are flagged.","parameters":[{"name":"article","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"content":{"type":"string","description":"string, required — comment text"},"parent":{"type":"string","description":"integer, optional — id of the comment you're replying to"}},"required":["content"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"content":{"type":"string","description":"string, required — comment text"},"parent":{"type":"string","description":"integer, optional — id of the comment you're replying to"}},"required":["content"]}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"example":{"data":{"id":178,"date":null,"status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone.","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":0,"userthumbed":0,"report":0,"isModerator":false,"replies":null},"meta":{},"badge":[{"id":50,"site":null,"name":"I never take things to heart","description":"Having said that, my 3 comments on that FML were really worth it.","hidden":true,"goal":1,"limited":"0","category":1,"total":7418,"illustration":"50-1.gif"}],"badge_display":[{"name":"I never take things to heart","description":"Having said that, my 3 comments on that FML were really worth it.","coin":"/images/badges/coins/50.webp?v=1793345964","gif":"/images/badges/50-1.gif"}]}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"No comment provided."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":["FML not found."],"meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/comment/{comment}/edit":{"post":{"operationId":"api_comment_edit","tags":["comments"],"summary":"Edit one of your comments","description":"Requires a user token. You can only edit your own comments (400 otherwise). Returns the updated comment (201).","parameters":[{"name":"comment","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"content":{"type":"string","description":"string, required — new comment text"}},"required":["content"]}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"content":{"type":"string","description":"string, required — new comment text"}},"required":["content"]}}}},"responses":{"201":{"description":"Success","content":{"application/json":{"example":{"data":{"id":178,"date":"2026-10-30T08:57:33+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":0,"userthumbed":0,"report":0,"isModerator":false,"replies":null},"meta":{},"badge":[],"badge_display":[]}}}},"400":{"description":"Error","content":{"application/json":{"example":{"error":"No comment provided."}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":["FML not found."],"meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/comment/{comment}/{replies}":{"get":{"operationId":"api_comment","tags":["comments"],"summary":"Get a comment by id","description":"Use `/comment/{comment}/replies` to include the comment's replies. When authenticated, your thumbs are included. Returns 404 if the comment doesn't exist.","parameters":[{"name":"comment","in":"path","required":true,"schema":{"type":"integer"}},{"name":"replies","in":"path","required":true,"schema":{"type":"string","enum":["replies"]}},{"name":"comment","in":"query","description":"integer, in the path — comment id","schema":{"type":"string"}},{"name":"replies","in":"query","description":"optional, in the path — the literal word `replies`, to include the replies","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"id":176,"date":"2026-10-30T08:56:01+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":2,"userthumbed":0,"report":1,"isModerator":false,"replies":null},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"error":"102 - Invalid API key."}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":[""],"meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: Invalid argument supplied for foreach()"}}}}},"security":[{"apiKey":[]},{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/comment/{comment}/up/{inc}":{"patch":{"operationId":"api_comment_up","tags":["comments"],"summary":"Give a comment a thumbs up","description":"Requires a user token. One thumb per member and comment: repeating the call changes nothing, and going from thumbs up to thumbs down (or the other way) moves the thumb. Returns the comment (202).","parameters":[{"name":"comment","in":"path","required":true,"schema":{"type":"integer"}},{"name":"inc","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"comment":{"type":"string","description":"integer, in the path — comment id"},"inc":{"type":"string","description":"integer, in the path — ignored: always one thumb"}}}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"comment":{"type":"string","description":"integer, in the path — comment id"},"inc":{"type":"string","description":"integer, in the path — ignored: always one thumb"}}}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"id":176,"date":"2026-10-30T08:56:01+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":2,"userthumbed":0,"report":1,"isModerator":false,"replies":null},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"","meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: Invalid argument supplied for foreach()"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/comment/{comment}/down/{inc}":{"patch":{"operationId":"api_comment_down","tags":["comments"],"summary":"Give a comment a thumbs down","description":"Requires a user token. One thumb per member and comment: repeating the call changes nothing, and going from thumbs up to thumbs down (or the other way) moves the thumb. A comment that gets too many thumbs down is hidden automatically (status 6, auto-nuked). Returns the comment (202).","parameters":[{"name":"comment","in":"path","required":true,"schema":{"type":"integer"}},{"name":"inc","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"comment":{"type":"string","description":"integer, in the path — comment id"},"inc":{"type":"string","description":"integer, in the path — ignored: always one thumb"}}}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"comment":{"type":"string","description":"integer, in the path — comment id"},"inc":{"type":"string","description":"integer, in the path — ignored: always one thumb"}}}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"id":176,"date":"2026-10-30T08:56:01+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":-1,"thumbdown":3,"userthumbed":0,"report":1,"isModerator":false,"replies":null},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"","meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: Invalid argument supplied for foreach()"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/comment/{comment}/report":{"patch":{"operationId":"api_comment_report_abuse","tags":["comments"],"summary":"Report a comment","description":"Requires a user token. One report per member and comment. Returns the comment (202), 404 if it doesn't exist.","parameters":[{"name":"comment","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"comment":{"type":"string","description":"integer, in the path — id of the comment to report"}}}},"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"comment":{"type":"string","description":"integer, in the path — id of the comment to report"}}}}}},"responses":{"202":{"description":"Success","content":{"application/json":{"example":{"data":{"id":176,"date":"2026-10-30T08:56:01+01:00","status":0,"parent":0,"content":"Same thing happened to me last week, you're not alone!","article":6,"author":{"id":1079692805,"username":"DocsTester","avatar":"/images/default-avatar.jpg","title":null},"thumbup":0,"thumbdown":3,"userthumbed":0,"report":1,"isModerator":false,"replies":null},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":"You must be authenticated in order to access this function.","meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"","meta":{},"badge":[],"badge_display":[]}}}},"500":{"description":"Error","content":{"application/json":{"example":{"error":"Warning: Invalid argument supplied for foreach()"}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/badge/{badgeid}":{"get":{"operationId":"api_badge","tags":["badges"],"summary":"Get a badge by id","description":"Requires a user token. Returns 404 if the badge doesn't exist.","parameters":[{"name":"badgeid","in":"path","required":true,"schema":{"type":"integer"}},{"name":"badgeid","in":"query","required":true,"description":"integer, required — badge id","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":{"id":1,"site":null,"name":"Beginner","description":"You have looked through 5 pages of the website. That’s a start.","hidden":"0","goal":5,"limited":"0","category":1,"total":7698968,"illustration":"lI6nHr5hWXlu0.gif"},"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}},"404":{"description":"Error","content":{"application/json":{"example":{"data":"Badge not found.","meta":{},"badge":[],"badge_display":[]}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}},"/badge/list":{"get":{"operationId":"api_badge_list","tags":["badges"],"summary":"List badges","description":"Requires a user token. Returns every badge except hidden ones.","responses":{"200":{"description":"Success","content":{"application/json":{"example":{"data":[{"id":1,"site":null,"name":"Beginner","description":"You have looked through 5 pages of the website. That’s a start.","hidden":"0","goal":5,"limited":"0","category":1,"total":7698968,"illustration":"lI6nHr5hWXlu0.gif"},{"id":2,"site":null,"name":"Profile completed","description":"You’ve filled out the necessary details. Having done so will be much appreciated.","hidden":"0","goal":1,"limited":"0","category":1,"total":192675,"illustration":"2.gif"}],"meta":{},"badge":[],"badge_display":[]}}}},"401":{"description":"Error","content":{"application/json":{"example":{"data":["You must be authenticated in order to access this function."],"meta":{},"badge":[],"badge_display":[]}}}}},"security":[{"apiKey":[],"memberToken":[]},{"apiKey":[],"oauth2":["api"]}]}}},"components":{"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"X-VDM-Api-Key","description":"Your API key (https://apps.fmylife.com/keys)"},"memberToken":{"type":"apiKey","in":"header","name":"X-VDM-Api-Token","description":"A member's token"},"oauth2":{"type":"oauth2","description":"Sign in with FML (https://apps.fmylife.com/docs/oauth)","flows":{"authorizationCode":{"authorizationUrl":"https://www.fmylife.com/oauth/authorize","tokenUrl":"https://www.fmylife.com/oauth/token","scopes":{"api":"The API on the member's behalf"}}}}}}}