Actions17
Custom Post Type → Get
AI-generatedSummary
Retrieve a custom post type record by ID
Inputs
- postType (required) — The post type to work with (choose from list or specify ID).
- cptId (required) — Unique identifier of the custom post type record to retrieve.
- cptGetOptions — Optional query options such as context (view, edit, embed).
Output shape
a single record
Returns the fields of the custom post type; optional context may adjust response fields.
Examples
Example 1: Get a specific custom post type record
Set resource=customPostType, operation=get, provide Post Type Name or ID, Record ID, optionally set Context to 'view'.
Example 2: Retrieve with edit context
In cptGetOptions, add an option 'Context' with value 'edit' to modify response fields.