microCMS

GET /api/v1/contents/{endpoint}/{content_id}

This is an API that allows you to retrieve the meta information of content specified by the id in a list-type API.

Request Header

X-MICROCMS-API-KEY

This is the authentication key required for GET API requests.
Please enable "Retrieve Content (List/Detail)" with the default permissions of the Management API and include it in the request header when sending.

cautionCaution

If the X-MICROCMS-API-KEY is identifiable, it may allow unauthorized manipulation of content by third parties. Please handle it with care. For more details, please refer to "API Key (API Authentication and Authorization Management)".

Response Body

This is an example of the content details response obtained from the Management API.

{
    "id": "contentId",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z",
    "publishedAt": "2019-08-24T14:15:22Z",
    "revisedAt": "2019-08-24T14:15:22Z",
    "closedAt": null,
    "status": [
      "DRAFT"
    ],
    "customStatus": null,
    "draftKey": "draftKey",
    "createdBy": "681dcd71-b7b9-4149-b45b-5e96eb51fecf",
    "updatedBy": "681dcd71-b7b9-4149-b45b-5e96eb51fecf",
    "reservationTime": {
      "publishTime": "2019-08-24T14:15:22Z",
      "stopTime": "2019-08-24T14:15:22Z" 
    }
}

The response includes the following items.

Value

Description

id

The ID of the content.

createdAt

The date and time when the content was created.

updatedAt

The date and time when the content was last updated.

publishedAt

The date and time when the content was published. If it has never been published, null will be present.

revisedAt

The date and time when the currently published content was updated. If it has never been published, null will be present.

draftKey

The draft key (draftKey) that can be obtained from the management screen. It will be null when the content is published or when the publication ends.

closedAt

The date and time when the publication ended. If it has never been closed, null will be present.

status

The status of the content. It can be one of DRAFT, PUBLISH, CLOSED, or PUBLISH_AND_DRAFT.

customStatus

The information of the custom status that has been set. If not set, null will be present. For details, please refer to "Custom Status".

createdBy

The ID of the member who created the content.

updatedBy

The ID of the member who last edited the content.

reservationTime

Information regarding the reservation for the start and end of publication.

If neither the start nor end reservation is set, null will be present.

If either the start or end reservation is set, it will include publishTime and stopTime. The one with a reservation will have a date and time, while the one without will have null.

Example: If only the start reservation is set

"reservationTime": { "publishTime": "2024-12-25T06:45:00Z", "stopTime": null }

Values Obtainable Only via the Management API

The following values are specific to the Management API. These values are not included in the Content API.

  • closedAt
  • status
  • customStatus
  • createdBy
  • updatedBy
  • reservationTime

Custom Status

For content with a custom status set, the customStatus will be included in the response as follows:

{
  "id": "contentId",
  "createdAt": "2019-08-24T14:15:22Z",
  "updatedAt": "2019-08-24T14:15:22Z",
  "publishedAt": "2019-08-24T14:15:22Z",
  "revisedAt": "2019-08-24T14:15:22Z",
  "status": [
    "PUBLISH"
  ],
  // This customStatus will be newly added.
  // If customStatus is not supported by the plan or not set, it will be null.
  "customStatus": [
    {
      "key": "USER_DEFINED_CUSTOM_STATUS_KEY123",
      "description": "This is a user-defined custom status.",
      "name": "Custom Status Test",
      "behaviour": "PUBLISH",
      "color": "#a20063",
      "createdAt": "2019-08-24T14:15:22Z",
      "updatedAt": "2019-08-24T14:15:22Z"
    }
  ],
  "draftKey": "draftKey",
  "createdBy": "681dcd71-b7b9-4149-b45b-5e96eb51fecf",
  "updatedBy": "681dcd71-b7b9-4149-b45b-5e96eb51fecf",
  "reservationTime": {
    "publishTime": "2019-08-24T14:15:22Z",
    "stopTime": "2019-08-24T14:15:22Z"
  }
}


For more details about custom status, please refer to the documentation below.