{"openapi":"3.1.0","info":{"title":"Wishes Public API","version":"v1","description":"Third-party access to a user's wishes, wishlists and friendships, built on the same action registry as the MCP server: every publicly registered action has a matching endpoint here."},"servers":[{"url":"https://api.wishes.bgmlv.com/api/public/v1"}],"paths":{"/list_wishes":{"get":{"operationId":"list_wishes","summary":"List wishes. Without user_id, lists the caller's own active wishes (requires authentication). With user_id, lists that user's wishes (active or realised) subject to friendship visibility — available to anonymous callers.","tags":["Wishes"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"page","in":"query","required":false,"description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1}},{"name":"per_page","in":"query","required":false,"description":"Items per page (1-100). Defaults to 20.","schema":{"type":"integer","minimum":1,"maximum":100}},{"name":"user_id","in":"query","required":false,"description":"Id of the wish owner whose wishes to list. Omit to list the caller's own wishes.","schema":{"type":"integer"}},{"name":"state","in":"query","required":false,"description":"Which wishes to list: 'active' or 'realised'. Defaults to 'active'. Only applies when user_id is given — the caller's own wishes (no user_id) are always active.","schema":{"type":"string","minLength":1,"enum":["active","realised"]}},{"name":"wishlist_id","in":"query","required":false,"description":"Restrict the list to this wishlist only. Only applies to the caller's own wishes (no user_id).","schema":{"type":"integer"}},{"name":"order","in":"query","required":false,"description":"Sort order. One of newest, oldest, created_at desc, created_at asc.","schema":{"type":"string","minLength":1,"enum":["newest","oldest","created_at desc","created_at asc"]}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/get_wish":{"get":{"operationId":"get_wish","summary":"Fetch a single wish by id, subject to friendship visibility.","tags":["Wishes"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"id","in":"query","required":true,"description":"Id of the resource.","schema":{"type":"integer"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/create_wish":{"post":{"operationId":"create_wish","summary":"Create a wish, optionally into a specific wishlist. Defaults to the inbox wishlist. Requires body or url; both left blank is rejected.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"body":{"type":"string","description":"Free-form text describing the wish. May be empty when url is given, but body or url is required."},"url":{"type":"string","description":"URL of the wished-for item. May be empty when body is given, but body or url is required."},"wishlist_id":{"type":"integer","description":"Wishlist to add the wish to. Defaults to the inbox wishlist."},"title":{"type":"string","description":"Title of the wished-for item, usually extracted from the URL."},"description":{"type":"string","description":"Longer description of the wished-for item."},"source_name":{"type":"string","description":"Name of the site the item was found on."},"image_remote_url":{"type":"string","description":"URL of an image representing the wished-for item."},"price_cents":{"type":"integer","description":"Price of the item, in cents."},"currency":{"type":"string","description":"Currency of price_cents, e.g. USD."},"multi_bookable":{"type":"boolean","description":"Whether more than one person may book this wish (e.g. a group gift). Defaults to false."}},"required":[]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed, wishlist_not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/create_wish_from_text":{"post":{"operationId":"create_wish_from_text","summary":"Create a wish by parsing free-form text, optionally containing a URL. Page metadata and images are fetched asynchronously.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","minLength":1,"description":"Free-form text describing the wish. May contain a product URL, which is parsed out automatically."},"wishlist_id":{"type":"integer","description":"Wishlist to add the wish to. Defaults to the inbox wishlist."}},"required":["text"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed, wishlist_not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/update_wish":{"post":{"operationId":"update_wish","summary":"Update a wish. Owner only.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Id of the wish to update."},"body":{"type":"string","description":"Free-form text describing the wish. May be empty when the wish is given by url alone."},"url":{"type":"string","description":"URL of the wished-for item. May be empty when the wish is described by text alone."},"wishlist_id":{"type":"integer","description":"Move the wish into this wishlist."},"title":{"type":"string","description":"Title of the wished-for item."},"description":{"type":"string","description":"Longer description of the wished-for item."},"source_name":{"type":"string","description":"Name of the site the item was found on."},"image_remote_url":{"type":"string","description":"URL of an image representing the wished-for item."},"price_cents":{"type":"integer","description":"Price of the item, in cents."},"currency":{"type":"string","description":"Currency of price_cents, e.g. USD."},"multi_bookable":{"type":"boolean","description":"Whether more than one person may book this wish. Cannot be turned off once multiple bookings exist."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed, wishlist_not_found, target_archived, has_multiple_bookings","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/delete_wish":{"post":{"operationId":"delete_wish","summary":"Delete a wish. Owner only.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Id of the resource."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean"},"id":{"type":"integer"}},"required":["deleted","id"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/realise_wish":{"post":{"operationId":"realise_wish","summary":"Mark a wish as realised. Owner only.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Id of the resource."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/unrealise_wish":{"post":{"operationId":"unrealise_wish","summary":"Move a realised wish back to active. Owner only.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Id of the resource."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/book_wish":{"post":{"operationId":"book_wish","summary":"Book (reserve) a wish for the caller.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Id of the wish to book."},"share_token":{"type":"string","minLength":1,"description":"The owning wishlist's share token, when the caller arrived via a share link rather than friendship."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed, already_booked","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/unbook_wish":{"post":{"operationId":"unbook_wish","summary":"Cancel the caller's own booking on a wish.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Id of the resource."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/move_wish":{"post":{"operationId":"move_wish","summary":"Move a wish into a different wishlist owned by the caller.","tags":["Wishes"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Id of the wish to move."},"wishlist_id":{"type":"integer","description":"Id of the destination wishlist. Must be owned by the caller and not archived."}},"required":["id","wishlist_id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}}}},"422":{"description":"validation_failed, target_archived","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden, not_owner, target_not_owned","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found, target_not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/search_wishes":{"get":{"operationId":"search_wishes","summary":"Full-text search over the caller's own wishes and their friends' wishes, matching against body, title, description and source_name. Handles Russian and English text, including a mix of both in the same wish, and ranks results by relevance.","tags":["Wishes"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"page","in":"query","required":false,"description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1}},{"name":"per_page","in":"query","required":false,"description":"Items per page (1-100). Defaults to 20.","schema":{"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":true,"description":"Search query, matched against body, title, description and source_name.","schema":{"type":"string","minLength":1}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/list_wishlists":{"get":{"operationId":"list_wishlists","summary":"List wishlists. Without user_id, lists the caller's own wishlists (requires authentication). With user_id, lists that user's wishlists visible to the caller (their own, a friend's shared ones, or nothing for a stranger) — available to anonymous callers.","tags":["Wishlists"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"page","in":"query","required":false,"description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1}},{"name":"per_page","in":"query","required":false,"description":"Items per page (1-100). Defaults to 20.","schema":{"type":"integer","minimum":1,"maximum":100}},{"name":"user_id","in":"query","required":false,"description":"ID of the user whose wishlists to list. Omit to list the caller's own wishlists.","schema":{"type":"integer"}},{"name":"state","in":"query","required":false,"description":"Filter by wishlist state (active or archived).","schema":{"type":"string","minLength":1,"enum":["active","archived"]}},{"name":"visibility","in":"query","required":false,"description":"Filter by wishlist visibility (shared, private; legacy friends/link_only accepted and normalized to shared).","schema":{"type":"string","minLength":1,"enum":["shared","private","friends","link_only"]}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"name":{"type":"string"},"description":{"type":["string","null"]},"visibility":{"type":"string","enum":["shared","private"]},"state":{"type":"string","enum":["active","archived"]},"is_inbox":{"type":"boolean"},"share_url":{"type":"string"},"occasion_type":{"type":["string","null"],"enum":["birthday","wedding","christmas","new_year","other",null]},"occasion_date":{"type":["string","null"],"format":"date"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"wishes_count":{"type":"integer"},"share_token":{"type":"string","description":"Owner only."},"active_bookings_count":{"type":"integer","description":"Owner only."}},"required":["id","user_id","name","description","visibility","state","is_inbox","share_url","occasion_type","occasion_date","archived_at","created_at","updated_at","wishes_count"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/get_wishlist":{"get":{"operationId":"get_wishlist","summary":"Get a wishlist by id, including its active wishes, if visible to the caller.","tags":["Wishlists"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"id","in":"query","required":true,"description":"Wishlist id.","schema":{"type":"integer"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"name":{"type":"string"},"description":{"type":["string","null"]},"visibility":{"type":"string","enum":["shared","private"]},"state":{"type":"string","enum":["active","archived"]},"is_inbox":{"type":"boolean"},"share_url":{"type":"string"},"occasion_type":{"type":["string","null"],"enum":["birthday","wedding","christmas","new_year","other",null]},"occasion_date":{"type":["string","null"],"format":"date"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"wishes_count":{"type":"integer"},"share_token":{"type":"string","description":"Owner only."},"active_bookings_count":{"type":"integer","description":"Owner only."},"archived":{"type":"boolean","description":"Present and true when read access was granted to an archived list."},"wishes":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}},"required":["id","user_id","name","description","visibility","state","is_inbox","share_url","occasion_type","occasion_date","archived_at","created_at","updated_at","wishes_count","wishes"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/list_wishlist_wishes":{"get":{"operationId":"list_wishlist_wishes","summary":"List the active wishes in a wishlist, if the wishlist is visible to the caller.","tags":["Wishlists"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"page","in":"query","required":false,"description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1}},{"name":"per_page","in":"query","required":false,"description":"Items per page (1-100). Defaults to 20.","schema":{"type":"integer","minimum":1,"maximum":100}},{"name":"id","in":"query","required":true,"description":"Wishlist id.","schema":{"type":"integer"}},{"name":"share_token","in":"query","required":false,"description":"The wishlist's share token, when the caller arrived via a share link rather than friendship.","schema":{"type":"string","minLength":1}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"body":{"type":["string","null"]},"url":{"type":["string","null"]},"title":{"type":["string","null"]},"description":{"type":["string","null"]},"source_name":{"type":["string","null"]},"image_remote_url":{"type":["string","null"]},"price_cents":{"type":["integer","null"]},"currency":{"type":["string","null"]},"state":{"type":"string","enum":["active","realised","cancelled"]},"multi_bookable":{"type":"boolean"},"bookings_count":{"type":["integer","null"],"description":"Hidden from the wish owner."},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"user_id":{"type":"integer"},"wishlist_id":{"type":"integer"},"user":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"booker_id":{"type":["integer","null"],"description":"Hidden from the wish owner."},"booker":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"booking":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"wish_id":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}},"required":["id","user_id","wish_id","created_at","updated_at"]},{"type":"null"}],"description":"Hidden from the wish owner."},"bookable":{"type":"boolean"},"picture_url":{"type":["string","null"]}},"required":["id","body","url","title","description","source_name","image_remote_url","price_cents","currency","state","multi_bookable","bookings_count","created_at","updated_at","user_id","wishlist_id","user","booker_id","booker","booking","bookable","picture_url"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/create_wishlist":{"post":{"operationId":"create_wishlist","summary":"Create a new wishlist owned by the current user.","tags":["Wishlists"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100,"description":"Wishlist name (max 100 characters)."},"description":{"type":"string","maxLength":1000,"description":"Free-text description (max 1000 characters)."},"visibility":{"type":"string","minLength":1,"enum":["shared","private","friends","link_only"],"description":"Visibility: shared or private (legacy friends/link_only accepted and normalized to shared); defaults to private."},"occasion_type":{"type":["null","string"],"enum":["birthday","wedding","christmas","new_year","other"],"description":"Occasion type (birthday, wedding, christmas, new_year, other), or null for none."},"occasion_date":{"type":["null","string"],"format":"date","description":"Occasion date, or null for none. Requires occasion_type to also be set."}},"required":["name"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"name":{"type":"string"},"description":{"type":["string","null"]},"visibility":{"type":"string","enum":["shared","private"]},"state":{"type":"string","enum":["active","archived"]},"is_inbox":{"type":"boolean"},"share_url":{"type":"string"},"occasion_type":{"type":["string","null"],"enum":["birthday","wedding","christmas","new_year","other",null]},"occasion_date":{"type":["string","null"],"format":"date"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"wishes_count":{"type":"integer"},"share_token":{"type":"string","description":"Owner only."},"active_bookings_count":{"type":"integer","description":"Owner only."}},"required":["id","user_id","name","description","visibility","state","is_inbox","share_url","occasion_type","occasion_date","archived_at","created_at","updated_at","wishes_count"]}}}},"422":{"description":"validation_failed, limit_reached","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/update_wishlist":{"post":{"operationId":"update_wishlist","summary":"Update an owned wishlist.","tags":["Wishlists"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Wishlist id."},"name":{"type":"string","minLength":1,"maxLength":100,"description":"New wishlist name (max 100 characters)."},"description":{"type":"string","maxLength":1000,"description":"New free-text description (max 1000 characters)."},"visibility":{"type":"string","minLength":1,"enum":["shared","private","friends","link_only"],"description":"New visibility: shared or private (legacy friends/link_only accepted and normalized to shared)."},"occasion_type":{"type":["null","string"],"enum":["birthday","wedding","christmas","new_year","other"],"description":"New occasion type (birthday, wedding, christmas, new_year, other). Pass null to clear it; omit to leave it alone."},"occasion_date":{"type":["null","string"],"format":"date","description":"New occasion date. Pass null to clear it; omit to leave it alone."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"name":{"type":"string"},"description":{"type":["string","null"]},"visibility":{"type":"string","enum":["shared","private"]},"state":{"type":"string","enum":["active","archived"]},"is_inbox":{"type":"boolean"},"share_url":{"type":"string"},"occasion_type":{"type":["string","null"],"enum":["birthday","wedding","christmas","new_year","other",null]},"occasion_date":{"type":["string","null"],"format":"date"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"wishes_count":{"type":"integer"},"share_token":{"type":"string","description":"Owner only."},"active_bookings_count":{"type":"integer","description":"Owner only."}},"required":["id","user_id","name","description","visibility","state","is_inbox","share_url","occasion_type","occasion_date","archived_at","created_at","updated_at","wishes_count"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/archive_wishlist":{"post":{"operationId":"archive_wishlist","summary":"Archive an owned wishlist. Fails if it has active bookings unless force_bookings is set.","tags":["Wishlists"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Wishlist id."},"force_bookings":{"type":"boolean","description":"Archive even if some of its wishes currently have active bookings."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"name":{"type":"string"},"description":{"type":["string","null"]},"visibility":{"type":"string","enum":["shared","private"]},"state":{"type":"string","enum":["active","archived"]},"is_inbox":{"type":"boolean"},"share_url":{"type":"string"},"occasion_type":{"type":["string","null"],"enum":["birthday","wedding","christmas","new_year","other",null]},"occasion_date":{"type":["string","null"],"format":"date"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"wishes_count":{"type":"integer"},"share_token":{"type":"string","description":"Owner only."},"active_bookings_count":{"type":"integer","description":"Owner only."}},"required":["id","user_id","name","description","visibility","state","is_inbox","share_url","occasion_type","occasion_date","archived_at","created_at","updated_at","wishes_count"]}}}},"422":{"description":"validation_failed, cannot_archive_inbox","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"409":{"description":"has_active_bookings","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/unarchive_wishlist":{"post":{"operationId":"unarchive_wishlist","summary":"Restore an archived wishlist to active state.","tags":["Wishlists"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Wishlist id."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"name":{"type":"string"},"description":{"type":["string","null"]},"visibility":{"type":"string","enum":["shared","private"]},"state":{"type":"string","enum":["active","archived"]},"is_inbox":{"type":"boolean"},"share_url":{"type":"string"},"occasion_type":{"type":["string","null"],"enum":["birthday","wedding","christmas","new_year","other",null]},"occasion_date":{"type":["string","null"],"format":"date"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"wishes_count":{"type":"integer"},"share_token":{"type":"string","description":"Owner only."},"active_bookings_count":{"type":"integer","description":"Owner only."}},"required":["id","user_id","name","description","visibility","state","is_inbox","share_url","occasion_type","occasion_date","archived_at","created_at","updated_at","wishes_count"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/set_inbox_wishlist":{"post":{"operationId":"set_inbox_wishlist","summary":"Mark an owned active wishlist as the inbox wishlist.","tags":["Wishlists"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer","description":"Wishlist id."}},"required":["id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"user_id":{"type":"integer"},"name":{"type":"string"},"description":{"type":["string","null"]},"visibility":{"type":"string","enum":["shared","private"]},"state":{"type":"string","enum":["active","archived"]},"is_inbox":{"type":"boolean"},"share_url":{"type":"string"},"occasion_type":{"type":["string","null"],"enum":["birthday","wedding","christmas","new_year","other",null]},"occasion_date":{"type":["string","null"],"format":"date"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"wishes_count":{"type":"integer"},"share_token":{"type":"string","description":"Owner only."},"active_bookings_count":{"type":"integer","description":"Owner only."}},"required":["id","user_id","name","description","visibility","state","is_inbox","share_url","occasion_type","occasion_date","archived_at","created_at","updated_at","wishes_count"]}}}},"422":{"description":"validation_failed, target_archived","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/list_friends":{"get":{"operationId":"list_friends","summary":"List the current user's friends, optionally filtered by name or username.","tags":["Friendships"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"page","in":"query","required":false,"description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1}},{"name":"per_page","in":"query","required":false,"description":"Items per page (1-100). Defaults to 20.","schema":{"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"description":"Filter friends by username, first name, or last name. Case-insensitive, tolerates typos, and matches across the Cyrillic/Latin script boundary (e.g. a query of \"Nikita\" also finds \"Никита\").","schema":{"type":["null","string"]}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/friendship_status":{"get":{"operationId":"friendship_status","summary":"Check the friendship status between the current user and another user.","tags":["Friendships"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"user_id","in":"query","required":true,"description":"ID of the other user to check the friendship status with.","schema":{"type":"integer"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["none","outgoing_pending","outgoing_accepted","outgoing_rejected","incoming_pending","incoming_accepted","incoming_rejected"]},"friendship":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"requester_id":{"type":"integer"},"addressee_id":{"type":"integer"},"status":{"type":"string","enum":["pending","accepted","rejected"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"requester":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"addressee":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]}},"required":["id","requester_id","addressee_id","status","created_at","updated_at","requester","addressee"]},{"type":"null"}]}},"required":["status","friendship"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/list_incoming_requests":{"get":{"operationId":"list_incoming_requests","summary":"List pending friend requests sent to the current user.","tags":["Friendships"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"page","in":"query","required":false,"description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1}},{"name":"per_page","in":"query","required":false,"description":"Items per page (1-100). Defaults to 20.","schema":{"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"requester_id":{"type":"integer"},"addressee_id":{"type":"integer"},"status":{"type":"string","enum":["pending","accepted","rejected"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"requester":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"addressee":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]}},"required":["id","requester_id","addressee_id","status","created_at","updated_at","requester","addressee"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/list_outgoing_requests":{"get":{"operationId":"list_outgoing_requests","summary":"List pending friend requests sent by the current user.","tags":["Friendships"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"page","in":"query","required":false,"description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1}},{"name":"per_page","in":"query","required":false,"description":"Items per page (1-100). Defaults to 20.","schema":{"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"requester_id":{"type":"integer"},"addressee_id":{"type":"integer"},"status":{"type":"string","enum":["pending","accepted","rejected"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"requester":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"addressee":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]}},"required":["id","requester_id","addressee_id","status","created_at","updated_at","requester","addressee"]}},"metadata":{"type":"object","properties":{"total_count":{"type":"integer"},"page":{"type":"integer"},"per_page":{"type":"integer"},"total_pages":{"type":"integer"}},"required":["total_count","page","per_page","total_pages"]}},"required":["data","metadata"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/send_friend_request":{"post":{"operationId":"send_friend_request","summary":"Send a friend request from the current user to another user.","tags":["Friendships"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"addressee_id":{"type":"integer","description":"ID of the user to send the friend request to."}},"required":["addressee_id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"requester_id":{"type":"integer"},"addressee_id":{"type":"integer"},"status":{"type":"string","enum":["pending","accepted","rejected"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"requester":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"addressee":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]}},"required":["id","requester_id","addressee_id","status","created_at","updated_at","requester","addressee"]}}}},"422":{"description":"validation_failed, cannot_friend_yourself, requester_not_found, addressee_not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"409":{"description":"already_friends, request_already_sent","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/accept_friend_request":{"post":{"operationId":"accept_friend_request","summary":"Accept a pending friend request sent to the current user.","tags":["Friendships"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"friendship_id":{"type":"integer","description":"ID of the friend request (friendship) to accept."}},"required":["friendship_id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"requester_id":{"type":"integer"},"addressee_id":{"type":"integer"},"status":{"type":"string","enum":["pending","accepted","rejected"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"requester":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"addressee":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]}},"required":["id","requester_id","addressee_id","status","created_at","updated_at","requester","addressee"]}}}},"422":{"description":"validation_failed, not_pending","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/reject_friend_request":{"post":{"operationId":"reject_friend_request","summary":"Reject a pending friend request sent to the current user.","tags":["Friendships"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"friendship_id":{"type":"integer","description":"ID of the friend request (friendship) to reject."}},"required":["friendship_id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"requester_id":{"type":"integer"},"addressee_id":{"type":"integer"},"status":{"type":"string","enum":["pending","accepted","rejected"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"requester":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]},"addressee":{"anyOf":[{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]},{"type":"null"}]}},"required":["id","requester_id","addressee_id","status","created_at","updated_at","requester","addressee"]}}}},"422":{"description":"validation_failed, not_pending","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/cancel_friend_request":{"post":{"operationId":"cancel_friend_request","summary":"Cancel a pending friend request sent by the current user.","tags":["Friendships"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"friendship_id":{"type":"integer","description":"ID of the friend request (friendship) to cancel."}},"required":["friendship_id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean"},"id":{"type":"integer"}},"required":["deleted","id"]}}}},"422":{"description":"validation_failed, not_pending","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/remove_friendship":{"post":{"operationId":"remove_friendship","summary":"Remove an accepted friendship. Either party may do this.","tags":["Friendships"],"security":[{"oauth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"friendship_id":{"type":"integer","description":"ID of the friendship to remove."}},"required":["friendship_id"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean"},"id":{"type":"integer"}},"required":["deleted","id"]}}}},"422":{"description":"validation_failed, not_accepted","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}},"/get_user":{"get":{"operationId":"get_user","summary":"Fetch a user profile by id.","tags":["Users"],"security":[{"oauth2":["read"]}],"parameters":[{"name":"id","in":"query","required":true,"description":"Id of the resource.","schema":{"type":"integer"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":["string","null"]},"firstname":{"type":["string","null"]},"lastname":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"},"email":{"type":["string","null"],"description":"Own profile only."},"google_linked":{"type":"boolean","description":"Own profile only."},"telegram_id":{"type":["string","null"],"description":"Own profile only."},"friendship_id":{"type":["integer","null"],"description":"Present where the caller asked about a friendship."},"friendship_status":{"type":["string","null"],"description":"Present where the caller asked about a friendship."},"last_activity_at":{"type":["string","null"],"format":"date-time","description":"Friends list only."},"visible_wishlists_count":{"type":"integer","description":"Friends list only."},"wishlists_preview":{"type":"array","items":{"type":"object"},"description":"Friends list only."}},"required":["id","username","firstname","lastname","created_at","updated_at"]}}}},"422":{"description":"validation_failed","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"401":{"description":"invalid_request, invalid_token","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"403":{"description":"forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"404":{"description":"not_found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"500":{"description":"internal_error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}},"429":{"description":"too_many_requests","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"details":{"type":"array"}},"required":["error","message"]}}}}}}}},"components":{"securitySchemes":{"oauth2":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"https://api.wishes.bgmlv.com/oauth/authorize","tokenUrl":"https://api.wishes.bgmlv.com/oauth/token","scopes":{"read":"Read the caller's wishes, wishlists and friendships.","write":"Create, update and delete the caller's wishes, wishlists and friendships."}}}}}}}