Migrations

Import API

The import API lets you import a migration package from your Octopus Server's built-in package feed (which is where packages are pushed to when using the partial-export API).

post/migrations/import

Request body

DeletePackageOnCompletionboolean

Removes the migration package that you're importing from on successful completion of the import

FailureCallbackUristring

A webhook URL you can add if you wish to be notified on failure of the migration task (Your Octopus Server will call this URL using a GET request)

IsDryRunboolean

Do not commit changes, just print what would have happened (This allows you to test an import without actually committing the transaction)

IsEncryptedPackageboolean

Tells us whether the package was encrypted (E.g. if you set EncryptPackage on export, you need to set this to True)

OverwriteExistingboolean

If a document with the same name already exists, it will be skipped by default

PackageFeedSpaceIdstring

If using the Spaces feature, the ID of the Space where the package containing the data to migrate will be uploaded. This is only for the package; the data in the package specifies its own destination Space.

PackageIdstring required

Package Name/ID that we are importing

PackageVersionstring required

SemVer package version that we are importing

Passwordstring required

Password that was used during the export migration (This is the shared key between partial-export and import migrations)

SuccessCallbackUristring

A webhook URL you can add if you wish to be notified on successful completion of the migration task (Your Octopus Server will call this URL using a GET request, appending the packageId and packageVersion to the URL)

Example request

{
  "IsDryRun": true,
  "IsEncryptedPackage": true,
  "PackageFeedSpaceId": "Spaces-1",
  "PackageId": "MyAwesomeOctopusMigration",
  "PackageVersion": "1.0.0",
  "Password": "Demo1234"
}

Response

The requested import task that has been queued.

DeletePackageOnCompletionboolean
FailureCallbackUristring
Idstring

Gets or sets a unique identifier for this resource.

IsDryRunboolean
IsEncryptedPackageboolean
LastModifiedBystring

Gets or sets the username of the user who last modified this resource.

LastModifiedOnstring date-time

Gets or sets the date/time that this resource was last modified.

Linksobject

Gets or sets a dictionary of links to other related resources. These links can be used to navigate the resources on the server.

OverwriteExistingboolean
PackageFeedSpaceIdstring
PackageIdstring
PackageVersionstring
Passwordstring
SuccessCallbackUristring
TaskIdstring

This will be populated with the TaskId that gets queued for this migration

Example response

{
  "IsDryRun": true,
  "PackageFeedSpaceId": "Spaces-1",
  "PackageId": "MyAwesomeOctopusMigration",
  "PackageVersion": "1.0.0",
  "TaskId": "ServerTasks-1234"
}

Changes

No recorded changes to this endpoint across all 7 revisions of this API.