---
updatedAt: 2026-04-21T15:17:50.000Z
agentTools:
  siteIndex: https://developers.pismo.io/llms.txt
  projectIndex: https://developers.pismo.io/pismo-docs/llms.txt
---

# Migrate statements

Start migration of statements.

This endpoint generates the following events:

- [Statement migration started](https://developers.pismo.io/events/docs/migration-statement-incoming-1)

- [Statement migration completed](https://developers.pismo.io/events/docs/migration-statement-outgoing-1)


# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Migrations",
    "version": "0.0.7",
    "description": "Use this service to migrate **entities** (including accounts, customer data, card data, and transaction history) from an external system to the Pismo platform.\n\nFor more information, refer to [Migrations overview](https://developers.pismo.io/pismo-docs/docs/migrations-overview).\n",
    "contact": {
      "name": "API Support",
      "url": "https://developers.pismo.io/support/"
    },
    "license": {
      "name": "Copyright Pismo"
    }
  },
  "servers": [
    {
      "url": "https://gw-pci.pismolabs.io/migrations",
      "description": "EXT API server for testing"
    },
    {
      "url": "https://sandbox.pismolabs.io/migrations",
      "description": "Sandbox API server for testing"
    }
  ],
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "tags": [
    {
      "name": "Statement migration",
      "description": "Statement migration"
    }
  ],
  "components": {
    "parameters": {
      "auth": {
        "name": "Authorization",
        "in": "header",
        "schema": {
          "type": "string"
        },
        "required": true,
        "description": "JSON Web Token (JWT). Tokens expire quickly, which can result in an **Unauthorized** message. For more information on authentication best practices, refer to [Basic authentication with client credentials](https://developers.pismo.io/pismo-docs/docs/basic-authentication-with-client-credentials#initial-authentication).\n",
        "example": "eyJ...F8E"
      }
    },
    "schemas": {
      "PostStatementsV1Request": {
        "title": "Statement migrations",
        "type": "object",
        "properties": {
          "migration": {
            "type": "object",
            "description": "Applicant additional migration information",
            "required": [
              "id",
              "version_date"
            ],
            "properties": {
              "id": {
                "type": "string",
                "description": "ID that you generate for migration purposes",
                "example": "5a8ade4e-e89a-11eb-9dd1-4b56d86f7a21"
              },
              "version_date": {
                "$ref": "#/components/schemas/VersionDate"
              },
              "account_id": {
                "type": "string",
                "description": "Set to the value in `applicant.migration.id` from the [Migrate accounts](https://developers.pismo.io/pismo-docs/reference/postaccountsv1) endpoint. This field links statements to an account.",
                "example": "EXTID1001"
              }
            }
          },
          "cycle_closing_date": {
            "type": "string",
            "format": "date",
            "description": "Cycle closing date",
            "example": "2018-03-15"
          },
          "best_transaction_day": {
            "type": "string",
            "format": "date",
            "description": "Day of best transaction. This is the cycle closing date of a credit card account. For purchases made after the cycle closes, payment is due in the next statement.\n",
            "example": "2018-03-16"
          },
          "due_date": {
            "type": "string",
            "format": "date",
            "description": "Due date",
            "example": "2018-03-25"
          },
          "real_due_date": {
            "type": "string",
            "format": "date",
            "description": "If a due date falls on a nonbusiness day, such as weekend or a holiday, the actual due date is the next business day on which the payment can be made. (Otherwise, it's the same as the due date.) Interest isn't charged until the real due date.\n",
            "example": "2018-03-25"
          },
          "previous_balance": {
            "type": "number",
            "format": "float",
            "description": "Value of previous balance",
            "example": 180.52
          },
          "debits": {
            "type": "number",
            "format": "float",
            "description": "Total debits of statement",
            "example": 50
          },
          "credits": {
            "type": "number",
            "format": "float",
            "description": "Total credits of statement",
            "example": 50
          },
          "current_balance": {
            "type": "number",
            "format": "float",
            "description": "Current balance",
            "example": 190.52
          },
          "minimum_payment": {
            "type": "number",
            "format": "float",
            "description": "Minimun payment",
            "example": 20
          },
          "posted_date": {
            "type": "string",
            "format": "date-time",
            "description": "Posted date",
            "example": "2021-10-25T19:54:41Z"
          },
          "posted_fine": {
            "type": "boolean",
            "description": "Is fine posted?",
            "example": false
          },
          "metadata": {
            "type": "object",
            "description": "Statements metadata\n\n**Note**: This field must not be used to send Personally Identifiable Information (PII), Payment Card Industry (PCI) data, or any sensitive/regulated information. Metadata fields are intended for operational, non-sensitive data only. For sensitive data, use the specific parameters designed for that  purpose. For more information, refer to [Get started with Pismo APIs](https://developers.pismo.io/pismo-docs/reference/get-started-with-pismo-apis).\n",
            "example": {
              "key1": "value1",
              "key2": "value2"
            }
          }
        }
      },
      "VersionDate": {
        "type": "string",
        "format": "date-time",
        "description": "Date-time when the record was created or last updated. Format = `yyyy-MM-ddTHH:mm:ss[.SSS][.SS][.S]Z`. Used together with the migration ID to ensure idempotency when updating data.\n\nWhen the Pismo platform receives a request with an existing migration ID, it rejects the request **unless** the `version_date` is later than the existing record's `version_date`.\n",
        "example": "2021-09-13T19:54:41Z"
      },
      "ErrorResponse": {
        "title": "ErrorResponse",
        "type": "object",
        "required": [
          "message"
        ],
        "properties": {
          "message": {
            "description": "Message describing the error",
            "type": "string",
            "example": "Internal error"
          },
          "code": {
            "type": "string",
            "description": "Payload validation error",
            "example": "MIGR00001"
          }
        },
        "description": "Standard error response"
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    },
    "examples": {
      "InternalServerError": {
        "value": {
          "code": "MIGR00001",
          "message": "Something went wrong"
        }
      },
      "PayloadValidationError": {
        "value": {
          "code": "MIGR00002",
          "field": "field_path (the object that failed validation)",
          "message": "Field required"
        }
      }
    }
  },
  "paths": {
    "/v1/migrations/statements": {
      "post": {
        "description": "Start migration of statements.\n\nThis endpoint generates the following events:\n\n- [Statement migration started](https://developers.pismo.io/events/docs/migration-statement-incoming-1)\n\n- [Statement migration completed](https://developers.pismo.io/events/docs/migration-statement-outgoing-1)\n",
        "summary": "Migrate statements",
        "tags": [
          "Statement migration"
        ],
        "operationId": "PostStatementsV1",
        "parameters": [
          {
            "$ref": "#/components/parameters/auth"
          }
        ],
        "requestBody": {
          "description": "Start migration of statements",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostStatementsV1Request"
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad request",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ErrorResponse"
                    }
                  ]
                },
                "examples": {
                  "Payload Validation Error": {
                    "$ref": "#/components/examples/PayloadValidationError"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal error",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ErrorResponse"
                    }
                  ]
                },
                "examples": {
                  "Internal Server Error": {
                    "$ref": "#/components/examples/InternalServerError"
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}
```