Set gif preferences
Sets gif preferences for the authorised account.
PUT
/api/v1/messaging/preferences/gifmessaging: read_write1,000 requests/minute/key · all plansActive API keys: Free 1, Pro 5, Pro+ 5. The request rate is the same on every plan.
Message storage
Message text is encrypted at rest and decrypted for authorised requests. Channel access is restricted to spaces owned by the API key’s account; missing or inaccessible channels return 404. Editing or deleting a message additionally checks its author and can return 403.
Parameters
No path or query parameters.
Request body
application/json · required
| Name | Type | Required | Description |
|---|---|---|---|
version | number | Required | Version used for optimistic concurrency checks. Allowed values: 1. |
favorites | array<object> | Required | Favorites. At most 50 items. |
favorites[].provider | string | Required | Provider. Allowed values: "tenor", "giphy". |
favorites[].providerGifId | string | Required | Provider Gif Id. Minimum length: 1. Maximum length: 128. |
favorites[].title | string | Optional | Display title. Maximum length: 500. |
favorites[].description | string | Optional | Description of the resource. Maximum length: 1000. |
favorites[].previewUrl | string (uri) | Required | Preview Url. Maximum length: 2048. |
favorites[].mediaUrl | string (uri) | Required | Media Url. Maximum length: 2048. |
favorites[].tinyUrl | string (uri) | Optional | Tiny Url. Maximum length: 2048. |
favorites[].width | integer | Optional | Width. Greater than 0. |
favorites[].height | integer | Optional | Height. Greater than 0. |
favorites[].duration | number | Optional | Duration. Minimum: 0. |
favorites[].contentDescription | string | Optional | Content Description. Maximum length: 1000. |
favorites[].sourceUrl | string (uri) | Optional | Source Url. Maximum length: 2048. |
updatedAt | integer | Required | Most recent update time. Minimum: 0. |
Response schema
200
Successful response.
| Name | Type | Required | Description |
|---|---|---|---|
version | number | Required | Version used for optimistic concurrency checks. Allowed values: 1. |
favorites | array<object> | Required | Favorites. |
favorites[].provider | string | Required | Provider. Allowed values: "tenor", "giphy". |
favorites[].providerGifId | string | Required | Provider Gif Id. |
favorites[].title | string | Optional | Display title. |
favorites[].description | string | Optional | Description of the resource. |
favorites[].previewUrl | string | Required | Preview Url. |
favorites[].mediaUrl | string | Required | Media Url. |
favorites[].tinyUrl | string | Optional | Tiny Url. |
favorites[].width | number | Optional | Width. |
favorites[].height | number | Optional | Height. |
favorites[].duration | number | Optional | Duration. |
favorites[].contentDescription | string | Optional | Content Description. |
favorites[].sourceUrl | string | Optional | Source Url. |
updatedAt | number | Required | Most recent update time. |
Errors
400· JSON errorInvalid JSON body.
401· JSON errorMissing or invalid API key. Use Authorization: Bearer <token>.
403· JSON errorRequires messaging: read_write; ownership or feature restrictions may also deny access.
404· JSON errorRequest failed (NOT_FOUND).
409· JSON errorconflict.
429· JSON errorAPI rate limit exceeded (1000 requests per minute). Retry shortly.
500· JSON errorinternal server error.
503· JSON errorObject storage is not configured. Set MinIO (or compatible S3) env vars to upload files.
Request example
Set FLORALITY_KEY in your environment. These examples use demo identifiers.
curl --request PUT 'https://floralitys.com/api/v1/messaging/preferences/gif' \
--header "Authorization: Bearer $FLORALITY_KEY" \
--header "Content-Type: application/json" \
--data '{
"version": 1,
"favorites": [
{
"provider": "tenor",
"providerGifId": "11111111-1111-4111-8111-111111111111",
"title": "River",
"description": "A note from our demo system.",
"previewUrl": "https://example.com/demo",
"mediaUrl": "https://example.com/demo",
"tinyUrl": "https://example.com/demo",
"width": 1,
"height": 1,
"duration": 0,
"contentDescription": "A note from our demo system.",
"sourceUrl": "https://example.com/demo"
}
],
"updatedAt": 1767225600000
}'Responses
Successful response.
{
"version": 1,
"favorites": [
{
"provider": "tenor",
"providerGifId": "11111111-1111-4111-8111-111111111111",
"title": "River",
"description": "A note from our demo system.",
"previewUrl": "https://example.com/demo",
"mediaUrl": "https://example.com/demo",
"tinyUrl": "https://example.com/demo",
"width": 0,
"height": 0,
"duration": 0,
"contentDescription": "A note from our demo system.",
"sourceUrl": "https://example.com/demo"
}
],
"updatedAt": 1767225600000
}Example values are illustrative demo data.
