Imports
An import backfills historical posts from a connected account. You queue an import job against a social account; we fetch its past posts in the background and make them available alongside the ones you publish through PostFuze. Imports run asynchronously, so creating one returns immediately with a queued job you can poll.
These routes are mounted under a specific account, so every path begins with /social-accounts/{accountId}.
The import job object
| Field | Type | Description |
|---|---|---|
id | string | Unique identifier for the import job. |
social_account_id | string | The account being imported from. |
status | enum | pending, running, completed, or failed. |
from_date / to_date | string | null | The date window the import covers. |
imported_count | number | null | How many posts have been imported so far. |
error_message | string | null | Failure detail when the job did not complete. |
started_at / finished_at | timestamp | null | When processing began and ended. |
created_at | timestamp | When the job was queued. |
Start an import
POST /social-accounts/{accountId}/imports
Queues an import job for the account and returns it with status pending and HTTP 202 Accepted. All body fields are optional; omitting the date window imports the account’s most recent posts up to the limit. Returns 404 if the account is not found.
| Parameter | Type | Required | Description |
|---|---|---|---|
from_date | string | No | Start of the date window to import. |
to_date | string | No | End of the date window to import. |
limit | integer | No | Maximum number of posts to fetch (1–1000). Defaults to 100. |
curl https://api.postfuze.com/api/v1/social-accounts/a1b2c3d4-…/imports \
-H "Authorization: Bearer sk_live_…" \
-H "Content-Type: application/json" \
-d '{
"from_date": "2026-01-01",
"to_date": "2026-06-01",
"limit": 500
}'{
"id": "imp_3c2b1a09",
"social_account_id": "a1b2c3d4-…",
"status": "pending",
"from_date": "2026-01-01",
"to_date": "2026-06-01",
"imported_count": null,
"error_message": null,
"started_at": null,
"finished_at": null,
"created_at": "2026-06-09T12:30:00.000Z"
}List imports
GET /social-accounts/{accountId}/imports
Returns the import jobs for an account, newest first.
curl https://api.postfuze.com/api/v1/social-accounts/a1b2c3d4-…/imports \
-H "Authorization: Bearer sk_live_…"{
"data": [
{
"id": "imp_3c2b1a09",
"social_account_id": "a1b2c3d4-…",
"status": "completed",
"from_date": "2026-01-01",
"to_date": "2026-06-01",
"imported_count": 312,
"error_message": null,
"started_at": "2026-06-09T12:30:05.000Z",
"finished_at": "2026-06-09T12:31:40.000Z",
"created_at": "2026-06-09T12:30:00.000Z"
}
]
}Subscribe to the import.completed and import.failed webhook events to be notified when a job finishes instead of polling.