/api/v4/social/brands/updateAtualizar uma marca
Atualiza o nome, fuso horário, site, categorias, hashtags ou biografia de uma marca nas redes sociais.
Parâmetros
Corpo
| Nome | Tipo | Obrigatório | Descrição |
|---|---|---|---|
| input | object | obrigatório | Wrapper object. Every field below is a property of `input`, the entire body must be nested under it. |
| input.profileId | string | obrigatório | UUID of the brand to update. This is the same value used as the `brandId` path token elsewhere. |
| input.profileName | string | opcional | New display name. |
| input.timezone | object | opcional | New timezone as `{ label, tzCode, name, utc }`. `tzCode` is the IANA identifier that schedules are resolved against. |
| input.businessIntent | string | opcional | One or two sentences describing what the business does. |
| input.categories | array of strings | opcional | Business categories. Replaces the stored list rather than merging into it. |
| input.siteUrl | string | opcional | The brand's website. Changing it queues a fresh read of the site. |
| input.logo | string | opcional | Public https URL of the brand logo. |
| input.countryIso | string | opcional | Two-letter ISO country code. |
| input.bio | string | opcional | Short brand bio. |
| input.brandHashtags | array of strings | opcional | Replaces the brand's hashtag list. |
| input.competitorHashtags | array of strings | opcional | Replaces the competitor hashtag list. |
| input.contentPreferredLanguage | string | opcional | Preferred language for generated content, e.g. `en`. |
Exemplo de requisição
Corpo pronto para colar. Substitua os IDs e valores de exemplo pelos seus.
{ "input": { "profileId": "6f2c9a41-7b0e-4d55-9a2f-3c8e1d47b902", "profileName": "Jenny Home & Co.", "siteUrl": "https://jennyhomeandco.example", "brandHashtags": ["jennyhome", "handmadefurniture", "shoplocal"] }}Respostas
200Brand updated. The full brand is returned.
{ "data": { "updateSocialProfile": { "success": true, "error": null, "socialProfile": { "id": "6f2c9a41-7b0e-4d55-9a2f-3c8e1d47b902", "profileName": "Jenny Home & Co.", "archived": false, "logo": null, "profileLogo": null, "siteUrl": "https://jennyhomeandco.example", "countryIso": "US", "bio": "Handmade furniture for real homes.", "businessIntent": "A family-run home furnishings store selling handmade furniture and textiles.", "categories": ["Furniture Store", "Home Goods"], "brandHashtags": ["jennyhome", "handmadefurniture", "shoplocal"], "competitorHashtags": [], "connectedChannelCount": 3, "timezone": { "label": "(GMT-05:00) Eastern Time", "tzCode": "America/New_York", "name": "Eastern Standard Time", "utc": "-05:00" }, "contentPreferredLanguage": "en" } } }}200Validation failed. The status is still 200: read `success`.
{ "data": { "updateSocialProfile": { "success": false, "error": { "message": "SY95046: Unknown timezone", "code": "SY95046", "contextInfo": null }, "socialProfile": null } }}401Unauthenticated, missing or invalid API key.
404No brand with that ID on this account (`SY95043`).
Edita uma marca existente. A marca é identificada por input.profileId no corpo, não por um parâmetro de caminho, e é por isso que a rota é simplesmente POST /social/brands/update.
Caso de uso: manter a marca alinhada com seu próprio CRM. Quando um cliente renomear a empresa ou mudar o endereço do site, replique a alteração aqui para que o cabeçalho da marca e as sugestões do editor de publicações continuem corretos. Alterar siteUrl também coloca uma nova leitura do site na fila, para que as sugestões incorporem o novo texto sem nenhuma chamada adicional.
Observações.
- O corpo da requisição deve estar encapsulado em um objeto
input. - Verifique
success, não o status HTTP. Uma atualização rejeitada retornaHTTP 200comsuccess: falsee o motivo emerror. - Apenas
profileIdé obrigatório. Todos os outros campos são opcionais, portanto atualizações parciais funcionam: envie apenas os campos que você está alterando e os demais permanecerão inalterados. O campo de identificação aqui éprofileId, nãobrandId—brandIdé sempre apenas um token de caminho de URL. categories,brandHashtagsecompetitorHashtagssão substituídos, não mesclados, quando você os envia. Enviar[]esvazia a lista.- Alterar
timezoneafeta a forma como valores futuros descheduleDate/scheduleTimesão interpretados. As publicações já agendadas mantêm o instante determinado no agendamento; seus horários não são recalculados. Consulte a marca novamente comGET /social/brands/{brandId}para confirmar.
Operação de escrita: não executada na conta em produção. A requisição e a resposta exibidas são construídas a partir do esquema da API.
curl -X POST 'https://listingsapi.com/api/v4/social/brands/update' \ -H "Authorization: API $LISTINGSAPI_KEY" \ -H 'Content-Type: application/json' \ -d '{ "input": { "profileId": "6f2c9a41-7b0e-4d55-9a2f-3c8e1d47b902", "profileName": "Jenny Home & Co.", "siteUrl": "https://jennyhomeandco.example", "brandHashtags": [ "jennyhome", "handmadefurniture", "shoplocal" ] } }'