Esta versión de GitHub Enterprise Server se discontinuará el 2026-08-25. No se admiten versiones discontinuas. No se realizarán lanzamientos de patch, ni siquiera para problemas de seguridad críticos. Para mejorar el rendimiento, mejorar la seguridad y las nuevas características de GitHub Enterprise Server, consulte Información general del proceso de actualización. Para obtener ayuda con la actualización, GitHub Soporte técnico empresarial.
REST API endpoints for Enterprise Live Migrations
Use the REST API to manage Enterprise Live Migrations on your GitHub Enterprise Server instance.
Nota:
Enterprise Live Migrations está en versión preliminar pública y está sujeto a cambios.
List Enterprise Live Migrations
List Enterprise Live Migrations (ELM) for the current GHES appliance.
Tokens de acceso granulares para "List Enterprise Live Migrations"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "List Enterprise Live Migrations"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
page_size integer Number of results per page. |
after string Cursor for pagination. Use the value from |
status string Optional filter by migration status. Puede ser uno de los siguientes: |
Códigos de estado de respuesta HTTP para "List Enterprise Live Migrations"
| código de estado | Descripción |
|---|---|
200 | OK |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
422 | The migration service is missing the source or target credentials required to service this request. An organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
501 | Not implemented. |
Ejemplos de código para "List Enterprise Live Migrations"
Ejemplo de solicitud
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrationsResponse
Status: 200Create an Enterprise Live Migration
Create an Enterprise Live Migration (ELM) for a single repository on the current GHES appliance. The migration is created in a created state and is not started; run the start endpoint to launch backfill and live updates. Credentials are referenced by name (pat_name) rather than submitted inline, and are not echoed back in the response.
Tokens de acceso granulares para "Create an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Create an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
source_organization_login string ObligatorioSource organization login on the GHES appliance. |
source_repository_name string ObligatorioSource repository name. |
target_organization_login string ObligatorioTarget organization login on the destination GitHub environment. |
target_repository_name string ObligatorioTarget repository name. |
target_api_endpoint string ObligatorioMigration target API endpoint URL. Must be a valid HTTPS URL. |
pat_name string ObligatorioName of the organization-scoped migration credential set to use. The raw token is never submitted inline and is never returned in the response. |
target_visibility string Target repository visibility. Defaults to Puede ser uno de los siguientes: |
Códigos de estado de respuesta HTTP para "Create an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
201 | The migration was created. The response contains the new migration identifier and its expiration. No credentials are returned. |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
409 | Conflict. The request conflicts with the current state of the migration. |
422 | The migration service is missing the source or target credentials required to service this request. An organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
Ejemplos de código para "Create an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrationsThe migration was created. The response contains the new migration identifier and its expiration. No credentials are returned.
Status: 201Get an Enterprise Live Migration
Retrieve combined status, progress, cutover readiness, expiration, and timing for an Enterprise Live Migration (ELM) on the current GHES appliance.
Tokens de acceso granulares para "Get an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Get an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
migration_id string ObligatorioThe ID of the migration. |
Códigos de estado de respuesta HTTP para "Get an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
200 | OK |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
422 | The migration service is missing the source or target credentials required to service this request. An organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
Ejemplos de código para "Get an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrations/MIGRATION_IDResponse
Status: 200Cancel an Enterprise Live Migration
Cancel an Enterprise Live Migration (ELM) in progress. This terminates the migration: it is cancelled locally, aborted on the migration backend, and its work items are removed. This is a terminal action with no recovery — a subsequent status request reflects the terminated state.
Tokens de acceso granulares para "Cancel an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Cancel an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
migration_id string ObligatorioThe ID of the migration. |
Códigos de estado de respuesta HTTP para "Cancel an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
204 | The migration was cancelled. No content is returned; query the migration status to observe the terminal state. |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
409 | Conflict. The migration is not in a state that can be cancelled (for example, it has already completed or been terminated). |
422 | The migration service is missing the source or target credentials required to service this request. An organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
Ejemplos de código para "Cancel an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrations/MIGRATION_ID/cancelThe migration was cancelled. No content is returned; query the migration status to observe the terminal state.
Status: 204Cutover an Enterprise Live Migration
Initiate cutover for an Enterprise Live Migration (ELM), archiving the source repository and draining remaining changes. Cutover is asynchronous; the migration transitions through cutover_pending and cutover_finalizing to completed. No content is returned — query the migration status to observe progress.
Tokens de acceso granulares para "Cutover an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Cutover an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
migration_id string ObligatorioThe ID of the migration. |
| Nombre, Tipo, Descripción |
|---|
force boolean Bypass the cutover readiness checks and initiate cutover even when the migration is not reported as ready. Defaults to Valor predeterminado: |
Códigos de estado de respuesta HTTP para "Cutover an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
204 | Cutover was initiated. No content is returned; query the migration status to observe the cutover progress. |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
409 | Conflict. The migration is not ready for cutover (for example, backfill is still in progress, or the migration has already completed, been cancelled, or failed). |
422 | The migration service is missing the source or target credentials required to service this request. An organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
Ejemplos de código para "Cutover an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrations/MIGRATION_ID/cutoverCutover was initiated. No content is returned; query the migration status to observe the cutover progress.
Status: 204Pause an Enterprise Live Migration
Pause source-load work for an active Enterprise Live Migration (ELM). Backfill and Git synchronization are paused while live event collection and delivery continue. The operation is idempotent for a migration that is already paused. No content is returned; query the migration status to observe the durable state.
Tokens de acceso granulares para "Pause an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Pause an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
migration_id string ObligatorioThe unique identifier of the Enterprise Live Migration. |
Códigos de estado de respuesta HTTP para "Pause an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
204 | The migration was paused. No content is returned; query the migration status to confirm its current state. |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
409 | Conflict. The migration is not in a state that can be paused, such as when it has not been started or has already completed. |
422 | The pause request was accepted by the migration service, but the migration did not complete the transition to paused. Query the migration status and retry. This status is also returned when the migration service is missing the source or target credentials required to service the request; an organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
Ejemplos de código para "Pause an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrations/MIGRATION_ID/pauseThe migration was paused. No content is returned; query the migration status to confirm its current state.
Status: 204Resume an Enterprise Live Migration
Resume a paused Enterprise Live Migration (ELM). The migration is re-queued and resumes backfill and live updates. A subsequent status request reflects the resumed state.
Tokens de acceso granulares para "Resume an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Resume an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
migration_id string ObligatorioThe ID of the migration. |
Códigos de estado de respuesta HTTP para "Resume an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
204 | The migration was resumed. No content is returned; query the migration status to observe the resumed state. |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
409 | Conflict. The migration is not in a state that can be resumed (for example, it is not paused, or has completed or terminated). |
422 | The migration service is missing the source or target credentials required to service this request. An organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
Ejemplos de código para "Resume an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrations/MIGRATION_ID/resumeThe migration was resumed. No content is returned; query the migration status to observe the resumed state.
Status: 204Revert cutover for an Enterprise Live Migration
Revert cutover for an Enterprise Live Migration (ELM). This unarchives the source repository and terminates any cutover or migration still in progress so the source repository can be migrated again.
Tokens de acceso granulares para "Revert cutover for an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Revert cutover for an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
migration_id string ObligatorioThe ID of the migration. |
Códigos de estado de respuesta HTTP para "Revert cutover for an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
200 | The cutover was reverted. |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
409 | Conflict. The migration is not in a state where cutover can be reverted. |
422 | The migration service is missing the source or target credentials required to service this request. An organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
503 | Service unavailable |
Ejemplos de código para "Revert cutover for an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrations/MIGRATION_ID/revert-cutoverThe cutover was reverted.
Status: 200Start an Enterprise Live Migration
Start a created Enterprise Live Migration (ELM), launching backfill and enabling live updates. The migration must be in a startable state (for example, created, paused, or failed); preflight validation runs before the migration is queued unless it has been skipped.
Tokens de acceso granulares para "Start an Enterprise Live Migration"
Este punto de conexión no funciona con tokens de acceso de usuario de aplicación de GitHub, tokens de acceso de instalación de aplicaciones de GitHub ni tokens de acceso personales específicos.
Parámetros para "Start an Enterprise Live Migration"
| Nombre, Tipo, Descripción |
|---|
accept string Setting to |
| Nombre, Tipo, Descripción |
|---|
migration_id string ObligatorioThe ID of the migration. |
Códigos de estado de respuesta HTTP para "Start an Enterprise Live Migration"
| código de estado | Descripción |
|---|---|
204 | The migration was started (queued for execution). No content is returned; query the migration status to observe progress. |
400 | Bad Request |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
409 | Conflict. The migration is not in a state that can be started (for example, it has already been started or has completed). |
422 | The migration could not be started because preflight validation did not pass. Query the migration status for details. This status is also returned when the migration service is missing the source or target credentials required to service the request; an organization administrator must configure the required secrets before retrying. |
500 | Internal Error |
Ejemplos de código para "Start an Enterprise Live Migration"
Ejemplo de solicitud
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
http(s)://HOSTNAME/api/v3/enterprise/live-migrations/MIGRATION_ID/startThe migration was started (queued for execution). No content is returned; query the migration status to observe progress.
Status: 204