---
title: "Update a post"
method: PUT
path: "/posts/{post_id}"
tags: ["Posts"]
---

# Update a post

`PUT /posts/{post_id}`

This endpoint lets you update a post.

When used by a BM or GM user, this endpoint also serves to validate and publish a draft post.  

The update will not happen in real time and might take a few minutes

⚠️ Due to Instagram API limitations, **this operation has no effect on Instagram posts**.

## Path parameters

- `post_id` number, required

## Request body

- PostUpdateData — Request body to update a Post
  - `title` string — Title of the post.
  - `summary` string — Main text content of the post.
  - `image_url` union — URLs of the images displayed with the post. **Note:** - Add up to 10 images for multi-image post on Facebook and IG - Multi-image is not supported by Google, only the first image will be displayed - Image ratio must be between 4:5 and 16:9 for IG - All images must be same ratio for IG or they will be crop at the first image ratio by IG
    - string
    - string[]
  - `cta_type` 'book' | 'order' | 'shop' | 'learn_more' | 'sign_up' | 'call' | 'no_cta' — The type of the post to be created. Some type mig.
  - `link` PostLink — Link displayed in the post to redirect the client clicking on it. Use can only have one of the following parameters ('use_business_url' or 'custom_url').
    - `use_business_url` boolean — Use the business google url for link on the post.
    - `custom_url` string — An URL to redirect client when they click on the button
  - `schedule_time` string — Date and time of when the post will be diffused corresponding platforms. It needs to be at least 2 hours after the time of the request. The timezone used is UTC.
  - `start_at` string — For either event or offer post type. Defined when it start. Timezone is defined by the business timezone.
  - `end_at` string — For either event or offer post type. Defined when it end. Timezone is defined by the business timezone.
  - `coupon_code` string — Offer code that is usable in store or online
  - `offer_terms` string — Terms and conditions of the offer

## Response `200`

OK

- Post — Post
  - `id` integer — The Post id
  - `business_id` string — Business id
  - `post_type` 'news' | 'event' | 'offer' | 'covid' — The type of the post to be created. Event and Offer are not yet available for Facebook.
  - `summary` string — Main text content of the post.
  - `schedule_time` string — Date when the Post will be published. No scheduled start time means that the Post will be published immediately.
  - `expiration_time` string — If this post is a draft, this indicates the date when it will be expired (= date after which the BM/GM user will no longer be able to validate and publish).
  - `validation_time` string — Date when the Draft post has been validated by the BM or GM user If the post doesn't also have a schedule time, this date coincides with the publishing date
  - `post_medias` object[] — The photo that will be on the Post
    - `media_url` union — URLs of the images displayed with the post. **Note:** - Add up to 10 images for multi-image post on Facebook and IG - Multi-image is not supported by Google, only the first image will be displayed - Image ratio must be between 4:5 and 16:9 for IG - All images must be same ratio for IG or they will be crop at the first image ratio by IG
      - string
      - string[]
  - `created_at` string, datetime — Creation date on Partoo
  - `updated_at` string, datetime — Last update date (either on Partoo or on Partner platform)
  - `created_on_partoo` boolean — Indicates whether or not the post was created using Partoo App/API
  - `updated_on_partoo` boolean — Indicates whether or not the post was updated using Partoo App/API
  - `business_info` string — name and address of the business that the post is related to.
  - `post_insight` object[] — Statistics related to the posts on the different platforms. ⚠️ Due to a Google deprecation, on 20/02/2023, Google views and counts won't be available anymore. Old insights will still be sent. Facebook ones will still be available.
    - `name` 'google_my_business__posts' | 'facebook__posts' — Publisher related to the post
    - `click_count` integer — number of times a user has clicked on the post.
    - `view_count` integer — number of times the post has been viewed.
  - `post_status` object[] — Status related to the posts on the different platforms.
    - `name` 'google_my_business__posts' | 'facebook__posts' — Publisher related to the post
    - `state` 'live' | 'pending' | 'to_configure' | 'scheduled' | 'error' | 'expired' — The state of the post, indicating at which lifecycle stage it is currently.
    - `link` string — Link displayed in the post to redirect the client clicking on it.
  - `offer_terms` string — Terms and conditions of the offer
  - `offer_code` string — Offer code that is usable in store or online
  - `cta_link` string — Link displayed in the post to redirect the client clicking on it.
  - `cta_type` 'book' | 'order' | 'shop' | 'learn_more' | 'sign_up' | 'call' | 'no_cta' — The type of the post to be created. Some type mig.

## Other responses

- `401` — You are not authenticated
- `403` — You are not allowed to perform this action
- `404` — Resource does not exist

---

[API](https://skmtc.net/partoo/apis/partoo-rest-api.md) · [All operations](https://skmtc.net/partoo/apis/partoo-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/partoo/partoo-rest-api/revisions/3652d8b1a8b3/schema)
