Operation contract · Instagram
social.instagram.post.read
Retrieves one public post or reel by canonical URL. Missing or inaccessible content returns an empty post object. Visible metrics are optional; private Insights are unavailable.
Contract identity
- Contract version
- 1.0.0
- Last verified
- Executable operations
- 11 / 40
Verified means the contract snapshot on this date was read and matched to the page. It is not a promise that an operation is live for your workspace.
Runtime contract description
Retrieves one public post or reel by canonical URL. Missing or inaccessible content returns an empty post object. Visible metrics are optional; private Insights are unavailable.
Input schema
| Field | Type | Required | Constraints / default | Description |
|---|---|---|---|---|
| (body) | object | Required | additional properties: false | Field description is not supplied by the contract. |
| url | string | Required | max length: 2048 · pattern: ^https://(?:www\.)?instagram\.com/(?:p|reel|tv)/[A-Za-z0-9_-]+/?$ | Canonical public Instagram post or reel URL; no query or fragment. |
Request example
{
"operation": "social.instagram.post.read",
"input": {
"url": "https://www.instagram.com/p/Sample123/"
},
"mode": "async"
}curl --fail-with-body -X POST https://api.datapi.ir/v1/requests \
-H "Authorization: Bearer $DATAPI_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"operation":"social.instagram.post.read","input":{"url":"https://www.instagram.com/p/Sample123/"},"mode":"async"}'Output schema
| Field | Type | Required | Constraints / default | Description |
|---|---|---|---|---|
| (body) | object | Required | additional properties: false | Field description is not supplied by the contract. |
| post | object | Required | additional properties: false | Field description is not supplied by the contract. |
| post.id | string | Optional | — | Field description is not supplied by the contract. |
| post.shortcode | string | Optional | — | Field description is not supplied by the contract. |
| post.permalink | string | Optional | — | Field description is not supplied by the contract. |
| post.author_id | string | Optional | — | Field description is not supplied by the contract. |
| post.author_username | string | Optional | — | Field description is not supplied by the contract. |
| post.caption | string | Optional | — | Field description is not supplied by the contract. |
| post.published_at | string (date-time) | Optional | format: date-time | Field description is not supplied by the contract. |
| post.format | string | Optional | enum: "image", "video", "carousel", "reel", "unknown" | Field description is not supplied by the contract. |
| post.likes_count | integer | Optional | min: 0 | Field description is not supplied by the contract. |
| post.comments_count | integer | Optional | min: 0 | Field description is not supplied by the contract. |
| post.views_count | integer | Optional | min: 0 | Field description is not supplied by the contract. |
| post.hashtags | array<string> | Optional | — | Field description is not supplied by the contract. |
| post.hashtags[] | string | Required | — | Field description is not supplied by the contract. |
| post.mentions | array<string> | Optional | — | Field description is not supplied by the contract. |
| post.mentions[] | string | Required | — | Field description is not supplied by the contract. |
Example result
This is the eventual operation data, not the HTTP 202 acceptance response or a live result. Submit the request, poll its status, then retrieve the result after success.
{
"post": {
"id": "sample-post",
"shortcode": "Sample123",
"caption": "Public post"
}
}How to call it
- Check availability with GET /v1/operations/{operation_id}.
- POST {operation, input, mode:"async"} to /v1/requests with an Idempotency-Key.
- Poll status_url or wait for the signed completion webhook.
- Read result_url only when result.available is true; 409 result_not_ready means wait, 410 result_expired means re-run the work.
Availability and limits
- All current operations support async only; mode=sync returns mode_not_supported.
- Size and runtime limits are declared by this operation contract; do not treat them as a global SLA.
- Results remain available for the retention window after success, then return 410.
Analytics computed from this data
An operation collects data; a metric family turns it into a number. These families are computed from this platform and data type, and each one states its formula and limits.