Update an Ambassador Post

PATCH /manager/posts/{id}

Path parameters

  • id integer(int32) Required

    The id of the ambassador post

application/json

Body Required

  • status string | null
  • contents array[object]
    Hide contents attributes Show contents attributes object
    • lang string

      Values are en_GB, fr_FR, es_ES, or de_DE.

    • content string
  • titles array[object]
    Hide titles attributes Show titles attributes object
    • lang string

      Values are en_GB, fr_FR, es_ES, or de_DE.

    • content string
  • shareable boolean
  • no_comment boolean
  • is_akn boolean
  • is_planned boolean
  • start_date string
  • visibility string | null

Responses

  • 200 application/json

    returns the updated ambassador post

    Hide response attributes Show response attributes object
    • id_ambassador_post integer(int32)
    • id_ambassador_post_shared integer(int32)
    • date_insert string(date-time)
    • date_update string(date-time)
    • author object
      Hide author attributes Show author attributes object
      • id_ambassador integer(int32)
      • image string
      • firstname string
      • lastname string
      • username string
      • email string
      • email_tmp string
      • active integer(int32)
      • status integer(int32)
      • online boolean

        true: when last_action_date is less than 5 minutes ago

      • last_action_date string(date-time)
      • customer_id string
      • anonymized boolean
    • type string(nullable)
    • content string(nullable)
    • nb_likes integer(int32)
    • nb_comments integer(int32)
    • visibility string(nullable)
    • products array[object]
      Hide products attributes Show products attributes object
      • id_product integer(int32)
      • name string(nullable)
      • type string(nullable)
      • discount_percentage number(float)
      • price_catalog integer(float)
      • reference_unit_price integer(float)
      • sku string(nullable)
      • youtube_id string(nullable)
      • url string(nullable)
      • description string(nullable)
      • images array[object]
        Hide images attributes Show images attributes object
        • id_i18n_content integer
        • lang string

          Values are en_GB, fr_FR, es_ES, or de_DE.

        • content string
      • price number(float)
      • stock integer(float)
      • stock_available number(float)
      • old_image string(nullable)
    • comments array[object]
      Hide comments attributes Show comments attributes object
      • id_ambassador_post integer(int32)
      • author object
        Hide author attributes Show author attributes object
        • id_ambassador integer(int32)
        • image string(nullable)
        • full_name string
        • username string(nullable)
        • description string
        • status integer(int32)
        • availability string(nullable)
        • unavailable boolean
        • is_absent boolean
        • absent_msg string(nullable)
        • fb_account string(nullable)
        • twitter_account string(nullable)
        • instagram_account string(nullable)
        • linkedIn_account string(nullable)
        • youtube_account string(nullable)
        • online boolean

          true: when last_action_date is less than 5 minutes ago

        • last_action_date string
      • content string(nullable)
      • nb_likes integer(int32)
      • comments array[object]
      • date_created string(date-time)
      • date_timestamp boolean
      • liked boolean
    • videos array[object]
      Hide videos attributes Show videos attributes object
      • id_video integer
      • date_insert string(date-time)
      • date_update string(date-time)
      • date_delete string(date-time)
      • id_blob string
      • state integer

        Values are 0, 1, 2, or 3.

    • nb_orders integer(int32)
    • liked boolean
    • contents array[object]
      Hide contents attributes Show contents attributes object
      • id_i18n_content integer
      • lang string

        Values are en_GB, fr_FR, es_ES, or de_DE.

      • content string
    • titles array[object]
      Hide titles attributes Show titles attributes object
      • id_i18n_content integer
      • lang string

        Values are en_GB, fr_FR, es_ES, or de_DE.

      • content string
    • is_planned boolean
    • shares integer(int32)
    • status string(nullable)
    • is_brand boolean
    • is_akn boolean
    • start_date string(date-time)
    • id_popliste number
    • video object
      Hide video attributes Show video attributes object
      • id_video integer
      • date_insert string(date-time)
      • date_update string(date-time)
      • date_delete string(date-time)
      • id_blob string
      • state integer

        Values are 0, 1, 2, or 3.

    • quiz object
      Hide quiz attributes Show quiz attributes object
      • id_quiz integer(int32)
      • active boolean
      • date_insert string(date-time)
      • date_update string(nullable)
      • start_date string(nullable)
      • end_date string(nullable)
      • acknowledge boolean
      • type_answer string(nullable)
      • type_callback string(nullable)
      • titles array[object]
        Hide titles attributes Show titles attributes object
        • id_i18n_content integer
        • lang string

          Values are en_GB, fr_FR, es_ES, or de_DE.

        • content string
      • descriptions array[object]
        Hide descriptions attributes Show descriptions attributes object
        • id_i18n_content integer
        • lang string

          Values are en_GB, fr_FR, es_ES, or de_DE.

        • content string
      • questions array[object]
        Hide questions attributes Show questions attributes object
        • id_i18n_content integer
        • lang string

          Values are en_GB, fr_FR, es_ES, or de_DE.

        • content string
      • callback_texts array[object]
        Hide callback_texts attributes Show callback_texts attributes object
        • id_i18n_content integer
        • lang string

          Values are en_GB, fr_FR, es_ES, or de_DE.

        • content string
      • answers object
        Hide answers attributes Show answers attributes object
        • id_quiz_answer integer(int32)
        • images array[object]
          Hide images attributes Show images attributes object
          • id_i18n_content integer
          • lang string

            Values are en_GB, fr_FR, es_ES, or de_DE.

          • content string
        • texts array[object]
          Hide texts attributes Show texts attributes object
          • id_i18n_content integer
          • lang string

            Values are en_GB, fr_FR, es_ES, or de_DE.

          • content string
        • is_correct boolean
        • nb_votes integer(int32)
      • ambassador_quiz_answer object
        Hide ambassador_quiz_answer attributes Show ambassador_quiz_answer attributes object
        • id_ambassador_quiz_answer integer(int32)
        • date_insert string(date-time)
        • ambassador object
          Hide ambassador attributes Show ambassador attributes object
          • id_ambassador integer(int32)
          • image string
          • firstname string
          • lastname string
          • username string
          • email string
          • email_tmp string
          • active integer(int32)
          • status integer(int32)
          • online boolean

            true: when last_action_date is less than 5 minutes ago

          • last_action_date string(date-time)
          • customer_id string
          • anonymized boolean
        • answer array[object]
          Hide answer attributes Show answer attributes object
          • id_i18n_content integer
          • lang string

            Values are en_GB, fr_FR, es_ES, or de_DE.

          • content string
      • answers_count integer(int32)
      • id_ambassador_post integer(int32)
      • my_answers array[string]
      • post object
        Hide post attributes Show post attributes object
        • id_ambassador_post integer(int32)
        • is_akn boolean
        • status string(nullable)
  • 401 application/json

    Unauthorized.

    Hide response attribute Show response attribute object
    • message string
  • 403

    Forbidden - You don't have permission to access this route

  • 404

    Not found

  • 422 application/json

    Unprocessable Content

    Hide response attributes Show response attributes object
    • message string

      Error message.

    • errors object
      Hide errors attributes Show errors attributes object
      • field array[string]

        Error message details.

      • * array[string] Additional properties

        Error message details.

PATCH /manager/posts/{id}
curl \
 --request PATCH 'https://domain.tld/api/v2/manager/posts/{id}' \
 --header "Authorization: Bearer $ACCESS_TOKEN" \
 --header "Content-Type: application/json" \
 --data '{"status":"string","contents":[{"lang":"en_GB","content":"Hello"}],"titles":[{"lang":"en_GB","content":"Hello"}],"shareable":true,"no_comment":true,"is_akn":true,"is_planned":true,"start_date":"string","visibility":"string"}'
Request examples
{
  "status": "string",
  "contents": [
    {
      "lang": "en_GB",
      "content": "Hello"
    }
  ],
  "titles": [
    {
      "lang": "en_GB",
      "content": "Hello"
    }
  ],
  "shareable": true,
  "no_comment": true,
  "is_akn": true,
  "is_planned": true,
  "start_date": "string",
  "visibility": "string"
}
Response examples (200)
{
  "id_ambassador_post": 42,
  "id_ambassador_post_shared": 42,
  "date_insert": "2025-05-04T09:42:00Z",
  "date_update": "2025-05-04T09:42:00Z",
  "author": {
    "id_ambassador": 42,
    "image": "string",
    "firstname": "string",
    "lastname": "string",
    "username": "string",
    "email": "string",
    "email_tmp": "string",
    "active": 42,
    "status": 42,
    "online": true,
    "last_action_date": "2025-05-04T09:42:00Z",
    "customer_id": "string",
    "anonymized": true
  },
  "type": "string",
  "content": "string",
  "nb_likes": 42,
  "nb_comments": 42,
  "visibility": "PUBLIC",
  "products": [
    {
      "id_product": 42,
      "name": "string",
      "type": "string",
      "discount_percentage": 42.0,
      "price_catalog": 42,
      "reference_unit_price": 42,
      "sku": "string",
      "youtube_id": "string",
      "url": "string",
      "description": "string",
      "images": [
        {
          "id_i18n_content": 42,
          "lang": "en_GB",
          "content": "Hello"
        }
      ],
      "price": 42.0,
      "stock": 42,
      "stock_available": 42.0,
      "old_image": "string"
    }
  ],
  "comments": [
    {
      "id_ambassador_post": 42,
      "author": {
        "id_ambassador": 42,
        "image": "string",
        "full_name": "string",
        "username": "string",
        "description": "string",
        "status": 42,
        "availability": "string",
        "unavailable": true,
        "is_absent": true,
        "absent_msg": "string",
        "fb_account": "string",
        "twitter_account": "string",
        "instagram_account": "string",
        "linkedIn_account": "string",
        "youtube_account": "string",
        "online": true,
        "last_action_date": "string"
      },
      "content": "string",
      "nb_likes": 42,
      "comments": [
        {}
      ],
      "date_created": "2025-05-04T09:42:00Z",
      "date_timestamp": true,
      "liked": true
    }
  ],
  "videos": [
    {
      "id_video": 1,
      "date_insert": "2023-10-09T12:12:40.220000Z",
      "date_update": "2023-10-09T12:12:40.220000Z",
      "date_delete": "2023-10-09T12:12:40.220000Z",
      "id_blob": "f0dab429-ae29-4e26-b6ea-138d351831eb",
      "state": 0
    }
  ],
  "nb_orders": 42,
  "liked": true,
  "contents": [
    {
      "id_i18n_content": 42,
      "lang": "en_GB",
      "content": "Hello"
    }
  ],
  "titles": [
    {
      "id_i18n_content": 42,
      "lang": "en_GB",
      "content": "Hello"
    }
  ],
  "is_planned": true,
  "shares": 42,
  "status": "PUBLISHED",
  "is_brand": true,
  "is_akn": true,
  "start_date": "2025-05-04T09:42:00Z",
  "id_popliste": 42.0,
  "video": {
    "id_video": 1,
    "date_insert": "2023-10-09T12:12:40.220000Z",
    "date_update": "2023-10-09T12:12:40.220000Z",
    "date_delete": "2023-10-09T12:12:40.220000Z",
    "id_blob": "f0dab429-ae29-4e26-b6ea-138d351831eb",
    "state": 0
  },
  "quiz": {
    "id_quiz": 42,
    "active": true,
    "date_insert": "2025-05-04T09:42:00Z",
    "date_update": "string",
    "start_date": "string",
    "end_date": "string",
    "acknowledge": true,
    "type_answer": "string",
    "type_callback": "string",
    "titles": [
      {
        "id_i18n_content": 42,
        "lang": "en_GB",
        "content": "Hello"
      }
    ],
    "descriptions": [
      {
        "id_i18n_content": 42,
        "lang": "en_GB",
        "content": "Hello"
      }
    ],
    "questions": [
      {
        "id_i18n_content": 42,
        "lang": "en_GB",
        "content": "Hello"
      }
    ],
    "callback_texts": [
      {
        "id_i18n_content": 42,
        "lang": "en_GB",
        "content": "Hello"
      }
    ],
    "answers": {
      "id_quiz_answer": 42,
      "images": [
        {
          "id_i18n_content": 42,
          "lang": "en_GB",
          "content": "Hello"
        }
      ],
      "texts": [
        {
          "id_i18n_content": 42,
          "lang": "en_GB",
          "content": "Hello"
        }
      ],
      "is_correct": "true",
      "nb_votes": 42
    },
    "ambassador_quiz_answer": {
      "id_ambassador_quiz_answer": 42,
      "date_insert": "2025-05-04T09:42:00Z",
      "ambassador": {
        "id_ambassador": 42,
        "image": "string",
        "firstname": "string",
        "lastname": "string",
        "username": "string",
        "email": "string",
        "email_tmp": "string",
        "active": 42,
        "status": 42,
        "online": true,
        "last_action_date": "2025-05-04T09:42:00Z",
        "customer_id": "string",
        "anonymized": true
      },
      "answer": [
        {
          "id_i18n_content": 42,
          "lang": "en_GB",
          "content": "Hello"
        }
      ]
    },
    "answers_count": 42,
    "id_ambassador_post": 42,
    "my_answers": [
      "string"
    ],
    "post": {
      "id_ambassador_post": 42,
      "is_akn": true,
      "status": "PUBLISHED"
    }
  }
}
Response examples (401)
{
  "message": "Unauthorized."
}
Response examples (422)
{
  "message": "field is required! (and 3 more error)",
  "errors": {
    "field": [
      "Error message details here"
    ],
    "additionalProperty1": [
      "Error message details here"
    ],
    "additionalProperty2": [
      "Error message details here"
    ]
  }
}