POST/api/v4/social/brands/update

Eine Marke aktualisieren

Aktualisiert den Namen, die Zeitzone, die Website, die Kategorien, die Hashtags oder die Biografie einer Marke in sozialen Medien.

Erfordert einen API-Schlüssel. Format des Headers und Schlüsselrotation finden Sie unter Authentifizierung.

Parameter

Body

NameTypErforderlichBeschreibung
inputobjecterforderlichWrapper object. Every field below is a property of `input`, the entire body must be nested under it.
input.profileIdstringerforderlichUUID of the brand to update. This is the same value used as the `brandId` path token elsewhere.
input.profileNamestringoptionalNew display name.
input.timezoneobjectoptionalNew timezone as `{ label, tzCode, name, utc }`. `tzCode` is the IANA identifier that schedules are resolved against.
input.businessIntentstringoptionalOne or two sentences describing what the business does.
input.categoriesarray of stringsoptionalBusiness categories. Replaces the stored list rather than merging into it.
input.siteUrlstringoptionalThe brand's website. Changing it queues a fresh read of the site.
input.logostringoptionalPublic https URL of the brand logo.
input.countryIsostringoptionalTwo-letter ISO country code.
input.biostringoptionalShort brand bio.
input.brandHashtagsarray of stringsoptionalReplaces the brand's hashtag list.
input.competitorHashtagsarray of stringsoptionalReplaces the competitor hashtag list.
input.contentPreferredLanguagestringoptionalPreferred language for generated content, e.g. `en`.

Beispielanfrage

Body zum direkten Einfügen. Ersetzen Sie Platzhalter-IDs und -Werte durch Ihre eigenen.

Request body
{  "input": {    "profileId": "6f2c9a41-7b0e-4d55-9a2f-3c8e1d47b902",    "profileName": "Jenny Home & Co.",    "siteUrl": "https://jennyhomeandco.example",    "brandHashtags": ["jennyhome", "handmadefurniture", "shoplocal"]  }}

Antworten

200Brand updated. The full brand is returned.
Response
{  "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`.
Response
{  "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`).

Bearbeitet eine bestehende Marke. Die Marke wird über input.profileId im Request-Body adressiert, nicht über einen Pfadparameter, weshalb die Route als flaches POST /social/brands/update aufgebaut ist.

Anwendungsfall: die Marke mit Ihrem eigenen CRM synchron halten. Wenn ein Kunde sein Unternehmen umbenennt oder seine Website an eine andere Adresse verlegt, übernehmen Sie die Änderung hier, damit die Kopfzeile der Marke und die Vorschläge im Beitragseditor korrekt bleiben. Eine Änderung von siteUrl reiht außerdem ein erneutes Auslesen der Website in die Warteschlange ein, sodass die Vorschläge die neuen Texte ohne weiteren Aufruf berücksichtigen.

Hinweise.

  • Der Request-Body muss in ein input-Objekt eingebettet sein.
  • Prüfen Sie success, nicht den HTTP-Status. Bei einer abgelehnten Aktualisierung wird HTTP 200 mit success: false und dem Grund in error zurückgegeben.
  • Nur profileId ist erforderlich. Alle anderen Felder sind optional, sodass Teilaktualisierungen möglich sind: Senden Sie nur die Felder, die Sie ändern möchten, und die übrigen bleiben unverändert. Das identifizierende Feld ist hier profileId, nicht brandId — brandId ist ausschließlich ein Token im URL-Pfad.
  • categories, brandHashtags und competitorHashtags werden beim Senden ersetzt, nicht zusammengeführt. Das Senden von [] leert die Liste.
  • Eine Änderung von timezone beeinflusst, wie künftige Werte für scheduleDate / scheduleTime interpretiert werden. Bereits geplante Beiträge behalten den Zeitpunkt bei, der für sie ermittelt wurde; sie werden nicht auf einen anderen Zeitpunkt verschoben. Lesen Sie die Marke mit GET /social/brands/{brandId} erneut aus, um dies zu bestätigen.

Schreiboperation: nicht im Live-Konto ausgeführt. Die gezeigte Anfrage und Antwort wurden anhand des API-Schemas erstellt.

Request
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"      ]    }  }'