cURL
curl --request GET 'https://api.integrateledger.com/v1/plans/starter/migrations/4' \
-H "Authorization: Bearer $LEDGER_API_KEY"import ledger from "integrateledger";
const client = new ledger({ apiKey: process.env.LEDGER_API_KEY ?? "" });
await client.getPlanMigration({ id: "starter", migrationId: 4 });import os
from integrateledger import ledger
client = ledger(api_key=os.environ["LEDGER_API_KEY"])
client.get_plan_migration("starter", 4){
"migrationId": 123,
"planId": "<string>",
"fromVersion": 123,
"toVersion": 123,
"timing": "now",
"status": "draft",
"customers": 1,
"byChange": {
"priceUp": 1,
"priceDown": 1,
"same": 1
},
"progress": {
"queued": 1,
"scheduled": 1,
"applied": 1
},
"skipped": [
{
"customerId": "<string>",
"reason": "pending_change"
}
]
}{
"error": "<string>",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment.",
"issues": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment.",
"issues": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "insufficient_permissions",
"requiredScope": "customers:read",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment."
}{
"error": "<string>",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment.",
"issues": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "rate_limited",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment."
}Plans
Get a plan migration
A migration’s preview, or its progress and skips once it runs.
GET
/
v1
/
plans
/
{id}
/
migrations
/
{migrationId}
cURL
curl --request GET 'https://api.integrateledger.com/v1/plans/starter/migrations/4' \
-H "Authorization: Bearer $LEDGER_API_KEY"import ledger from "integrateledger";
const client = new ledger({ apiKey: process.env.LEDGER_API_KEY ?? "" });
await client.getPlanMigration({ id: "starter", migrationId: 4 });import os
from integrateledger import ledger
client = ledger(api_key=os.environ["LEDGER_API_KEY"])
client.get_plan_migration("starter", 4){
"migrationId": 123,
"planId": "<string>",
"fromVersion": 123,
"toVersion": 123,
"timing": "now",
"status": "draft",
"customers": 1,
"byChange": {
"priceUp": 1,
"priceDown": 1,
"same": 1
},
"progress": {
"queued": 1,
"scheduled": 1,
"applied": 1
},
"skipped": [
{
"customerId": "<string>",
"reason": "pending_change"
}
]
}{
"error": "<string>",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment.",
"issues": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "<string>",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment.",
"issues": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "insufficient_permissions",
"requiredScope": "customers:read",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment."
}{
"error": "<string>",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment.",
"issues": [
{
"path": "<string>",
"message": "<string>"
}
]
}{
"error": "rate_limited",
"message": "No customer \"user_123\" exists in this environment. Create it with POST /v1/customers, or check that the API key is for the right environment."
}While the migration is a
draft, this is its preview. Once it runs, progress counts its moves: queued (not made yet), scheduled (waiting for the subscriber’s renewal) and applied. It is done when nothing is queued.
Needs the Catalog permission at Read.Authorizations
Path Parameters
Response
The migration