Imports
Importing external Postgres databases.
Org or project-scoped API key, format capy_live_...; Clerk session tokens also accepted.
In: header
Path Parameters
Project id.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/projects/string/imports" \ -H "Content-Type: application/json" \ -d '{ "confirm": true }'{ "job": { "attempts": 0, "claimed_at": "2019-08-24T14:15:22Z", "claimed_by": "string", "host_id": "string", "instance_id": "string", "completed_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "error": "string", "id": "string", "last_exit_code": 0, "last_stderr": "string", "last_stdout": "string", "locked_resource": "string", "max_attempts": 0, "organization_id": "string", "preview_database_id": "string", "project_id": "string", "result": null, "retry_classification": "string", "started_at": "2019-08-24T14:15:22Z", "state": "pending", "type": "project.apply_plan", "updated_at": "2019-08-24T14:15:22Z" }}Org or project-scoped API key, format capy_live_...; Clerk session tokens also accepted.
In: header
Path Parameters
Project id.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/projects/string/imports/uploads"{ "upload": { "object_key": "string", "upload_url": "string", "expires_at": "2019-08-24T14:15:22Z" }}Org or project-scoped API key, format capy_live_...; Clerk session tokens also accepted.
In: header
Path Parameters
Project id.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/projects/string/imports/preflight" \ -H "Content-Type: application/json" \ -d '{ "source_url": "string" }'{ "preflight": { "checks": [ { "detail": "string", "name": "string", "status": "pass" } ], "ok": true, "source": { "database_size_bytes": 0, "extensions": [ { "name": "string", "version": "string" } ], "server_version": "string", "app_schemas": [ "string" ], "provider_schemas": [ "string" ], "provider_auth_fks": [ { "constraint": "string", "source_table": "string", "target_table": "string" } ], "provider_auth_policy_tables": [ "string" ], "event_triggers": [ "string" ] }, "storage_limit_bytes": 0, "target_version": "string" }}Org or project-scoped API key, format capy_live_...; Clerk session tokens also accepted.
In: header
Path Parameters
Project id.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/projects/string/imports/follow" \ -H "Content-Type: application/json" \ -d '{ "source_url": "string", "confirm": true }'{ "job": { "attempts": 0, "claimed_at": "2019-08-24T14:15:22Z", "claimed_by": "string", "host_id": "string", "instance_id": "string", "completed_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "error": "string", "id": "string", "last_exit_code": 0, "last_stderr": "string", "last_stdout": "string", "locked_resource": "string", "max_attempts": 0, "organization_id": "string", "preview_database_id": "string", "project_id": "string", "result": null, "retry_classification": "string", "started_at": "2019-08-24T14:15:22Z", "state": "pending", "type": "project.apply_plan", "updated_at": "2019-08-24T14:15:22Z" }}Org or project-scoped API key, format capy_live_...; Clerk session tokens also accepted.
In: header
Path Parameters
Project id.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/projects/string/imports/follow/status"{ "job": { "attempts": 0, "claimed_at": "2019-08-24T14:15:22Z", "claimed_by": "string", "host_id": "string", "instance_id": "string", "completed_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "error": "string", "id": "string", "last_exit_code": 0, "last_stderr": "string", "last_stdout": "string", "locked_resource": "string", "max_attempts": 0, "organization_id": "string", "preview_database_id": "string", "project_id": "string", "result": null, "retry_classification": "string", "started_at": "2019-08-24T14:15:22Z", "state": "pending", "type": "project.apply_plan", "updated_at": "2019-08-24T14:15:22Z" }}Org or project-scoped API key, format capy_live_...; Clerk session tokens also accepted.
In: header
Path Parameters
Project id.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/projects/string/imports/follow/cutover" \ -H "Content-Type: application/json" \ -d '{ "confirm": true }'{ "job": { "attempts": 0, "claimed_at": "2019-08-24T14:15:22Z", "claimed_by": "string", "host_id": "string", "instance_id": "string", "completed_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "error": "string", "id": "string", "last_exit_code": 0, "last_stderr": "string", "last_stdout": "string", "locked_resource": "string", "max_attempts": 0, "organization_id": "string", "preview_database_id": "string", "project_id": "string", "result": null, "retry_classification": "string", "started_at": "2019-08-24T14:15:22Z", "state": "pending", "type": "project.apply_plan", "updated_at": "2019-08-24T14:15:22Z" }}Org or project-scoped API key, format capy_live_...; Clerk session tokens also accepted.
In: header
Path Parameters
Project id.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/projects/string/imports/follow/abort"{ "job": { "attempts": 0, "claimed_at": "2019-08-24T14:15:22Z", "claimed_by": "string", "host_id": "string", "instance_id": "string", "completed_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "error": "string", "id": "string", "last_exit_code": 0, "last_stderr": "string", "last_stdout": "string", "locked_resource": "string", "max_attempts": 0, "organization_id": "string", "preview_database_id": "string", "project_id": "string", "result": null, "retry_classification": "string", "started_at": "2019-08-24T14:15:22Z", "state": "pending", "type": "project.apply_plan", "updated_at": "2019-08-24T14:15:22Z" }}