{"meta":{"title":"Points de terminaison d’API REST pour la gestion de GitHub Enterprise Server","intro":"Utilisez l’API REST pour gérer votre GitHub Enterprise Server instance.","product":"API REST","breadcrumbs":[{"href":"/fr/enterprise-server@3.18/rest","title":"API REST"},{"href":"/fr/enterprise-server@3.18/rest/enterprise-admin","title":"Administration d’entreprise"},{"href":"/fr/enterprise-server@3.18/rest/enterprise-admin/manage-ghes","title":"Gérer GHES"}],"documentType":"article"},"body":"# Points de terminaison d’API REST pour la gestion de GitHub Enterprise Server\n\nUtilisez l’API REST pour gérer votre GitHub Enterprise Server instance.\n\n## À propos de l’API Gérer GitHub Enterprise Server\n\nVous pouvez gérer votre instance GitHub Enterprise Server à l’aide de l’API Gérer GitHub Enterprise Server . Par exemple, vous pouvez récupérer des informations sur la version du GitHub Enterprise Server logiciel en cours d’exécution sur l’instance ou sur des instances avec plusieurs nœuds, afficher l’état de la réplication.\n\n> \\[!TIP] Vous pouvez utiliser cette API pour remplacer les fonctionnalités de **l’API console de gestion**, qui a été supprimée dans GitHub Enterprise Server la version 3.15.\n\nSpécifiez le numéro de port lors de l’appel d’API aux points de terminaison pour l’API Gérer GitHub Enterprise Server . Si votre instance utilise TLS, le numéro de port est 8443. Sinon, le numéro de port est 8080. Si vous ne pouvez pas fournir un numéro de port, vous devez configurer votre client pour suivre automatiquement les redirections. Pour plus d’informations, consultez « [Configuration de TLS](/fr/enterprise-server@3.18/admin/configuring-settings/hardening-security-for-your-enterprise/configuring-tls) ».\n\nVous pouvez également utiliser l'extension GitHub Enterprise Server de GitHub CLI pour appeler les points de terminaison dans l'API de gestion GitHub Enterprise Server. Pour plus d’informations, consultez le dépôt [`github/gh-es`](https://github.com/github/gh-es/blob/main/README.md).\n\n### Authentification\n\nPour authentifier les demandes adressées aux points de terminaison de l’API Manage GitHub Enterprise Server , spécifiez le mot de passe du compte d’administrateur de site racine de l’instance en tant que jeton d’authentification. Utilisez une authentification HTTP standard pour envoyer le mot de passe. L’utilisateur `api_key` identifie l’administrateur de site racine. L’exemple suivant illustre l’authentification pour cette API. Remplacez ROOT-SITE-ADMINISTRATOR-PASSWORD par le mot de passe et ADMINISTRATION-PORT par 8443 ou 8080.\n\n```shell\ncurl -L -u \"api_key:ROOT-SITE-ADMINISTRATOR-PASSWORD\" 'http(s)://HOSTNAME:ADMINISTRATION-PORT/manage'\n```\n\n### Authentification en tant qu’utilisateur Console de gestion\n\nConsole de gestion les comptes d’utilisateur peuvent également s’authentifier pour accéder à ces points de terminaison. Pour plus d’informations, consultez « [Gestion de l’accès à la console de gestion](/fr/enterprise-server@3.18/admin/administering-your-instance/administering-your-instance-from-the-web-ui/managing-access-to-the-management-console#management-console-user) ».\n\nPour vous authentifier avec le mot de passe d’un compte d’utilisateur Console de gestion , utilisez l’authentification HTTP standard. Dans l’exemple suivant, remplacez YOUR\\_USER\\_NAME et YOUR\\_PASSWORD par le nom d’utilisateur et le mot de passe du compte.\n\n```shell\ncurl -L -u \"YOUR_USER_NAME:YOUR_PASSWORD\" 'http(s)://HOSTNAME:ADMINISTRATION-PORT/manage'\n```\n\n### Paramètres de requête\n\nPar défaut, la réponse inclut des informations sur tous les nœuds configurés pour l’instance. Sur une instance avec plusieurs nœuds, les détails proviennent de `/data/user/common/cluster.conf`. Vous pouvez utiliser les paramètres de requête suivants pour filtrer la réponse et obtenir des informations sur des nœuds spécifiques.\n\n| Paramètre de requête. | Description                                                                                                                                                                                                                                                  |\n| :-------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `uuid`                | Identificateur unique du nœud.                                                                                                                                                                                                                               |\n| `cluster_role`        | Pour les nœuds d’un cluster, les rôles qui s’appliquent au nœud. Pour plus d’informations, consultez « [À propos des nœuds de cluster](/fr/enterprise-server@3.18/admin/monitoring-and-managing-your-instance/configuring-clustering/about-cluster-nodes) ». |\n\nVous pouvez spécifier plusieurs valeurs pour le paramètre de requête en séparant les valeurs par une virgule. Par exemple, la requête suivante utilise curl pour retourner tous les nœuds ayant le rôle `web-server` ou `storage-server`.\n\n```shell\ncurl -L -u \"api_key:ROOT-SITE-ADMINISTRATOR-PASSWORD\" 'http(s)://HOSTNAME:ADMINISTRATION-PORT/manage/v1/config/nodes?cluster_role=WebServer,StorageServer'\n```\n\n> \\[!NOTE]\n> Most endpoints use `Authorization: Bearer <YOUR-TOKEN>` and `Accept: application/vnd.github+json` headers, plus `X-GitHub-Api-Version: 2022-11-28`. Curl examples below omit these standard headers for brevity.\n\n## Get the configured SSH keys\n\n```\nGET /manage/v1/access/ssh\n```\n\nGets the configured SSH keys on all available nodes. For more information, see \"Accessing the administrative shell (SSH).\"\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/access/ssh\n```\n\n**Response schema (Status: 200):**\n\nArray of objects:\n\n* `key`: string, format: ssh-key\n* `fingerprint`: string, format: ssh-key fingerprint\n\n## Set a new SSH key\n\n```\nPOST /manage/v1/access/ssh\n```\n\nAdds a SSH key to the authorized\\_keys file for your GitHub Enterprise Server instance. This will grant access via SSH to your instance. For more information, see \"Accessing the administrative shell (SSH).\"\n\n### Parameters\n\n#### Body parameters\n\n* **`key`** (string) (required)\n  The public SSH key to add to the authorized\\_keys file.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X POST \\\n  http(s)://HOSTNAME/manage/v1/access/ssh \\\n  -d '{\n  \"key\": \"ssh-rsa AAAAB3NzaC1yc2EAAAADCIABAAAAgQCY/ZiDDOFWcZnYXPwMbvwQDofXPdHxLfxPK+HWGVPd1DLcDncYBUSB0bmCU2g9Sc+oHKLoHhXp0ivau9h+EpmQJ7V8vqsRdD9pc4aL/WAnUyF4o3Y7xL94rlRpVbVo/tNjzcvqxxyzBiYyy3GciCMpYQh/uKt56B94/5PNyIGEEw==\"\n}'\n```\n\n**Response schema (Status: 200):**\n\nArray of objects:\n\n* `hostname`: string, format: hostname\n* `uuid`: string, format: uuid\n* `message`: string\n* `error`: string\n* `modified`: boolean\n\n## Delete a SSH key\n\n```\nDELETE /manage/v1/access/ssh\n```\n\nDeletes a SSH key from the authorized\\_keys file for your GitHub Enterprise Server instance. This will remove access via SSH to your instance. For more information, see \"Accessing the administrative shell (SSH).\"\n\n### Parameters\n\n#### Body parameters\n\n* **`key`** (string) (required)\n  The public SSH key to remove from the authorized\\_keys file.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X DELETE \\\n  http(s)://HOSTNAME/manage/v1/access/ssh \\\n  -d '{\n  \"key\": \"ssh-rsa AAAAB3NzaC1yc2EAAAADCIABAAAAgQCY/ZiDDOFWcZnYXPwMbvwQDofXPdHxLfxPK+HWGVPd1DLcDncYBUSB0bmCU2g9Sc+oHKLoHhXp0ivau9h+EpmQJ7V8vqsRdD9pc4aL/WAnUyF4o3Y7xL94rlRpVbVo/tNjzcvqxxyzBiYyy3GciCMpYQh/uKt56B94/5PNyIGEEw==\"\n}'\n```\n\n**Response schema (Status: 200):**\n\nArray of objects:\n\n* `hostname`: string, format: hostname\n* `uuid`: string, format: uuid\n* `message`: string\n* `error`: string\n\n## Get the system requirement check results for configured cluster nodes\n\n```\nGET /manage/v1/checks/system-requirements\n```\n\nChecks if the minimum requirements for system hardware resources are met on each configured cluster node.\nThis endpoint may take several seconds to reply.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/checks/system-requirements\n```\n\n**Response schema (Status: 200):**\n\n* `status`: string, enum: `OK`, `FAILED`\n* `nodes`: array of objects:\n  * `hostname`: string\n  * `status`: string, enum: `OK`, `FAILED`\n  * `roles_status`: array of objects:\n    * `status`: string, enum: `OK`, `FAILED`\n    * `role`: string\n\n## Get the status of services running on all cluster nodes\n\n```\nGET /manage/v1/cluster/status\n```\n\nGets the status of all services running on each cluster node.\nThis endpoint may take several seconds to reply.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/cluster/status\n```\n\n**Response schema (Status: 200):**\n\n* `status`: string, enum: `UNKNOWN`, `OK`, `WARNING`, `CRITICAL`\n* `nodes`: array of objects:\n  * `hostname`: string\n  * `status`: string, enum: `UNKNOWN`, `OK`, `WARNING`, `CRITICAL`\n  * `services`: array of objects:\n    * `status`: string, enum: `UNKNOWN`, `OK`, `WARNING`, `CRITICAL`\n    * `name`: string\n    * `details`: string\n\n## Get the status of a ghe-config-apply run\n\n```\nGET /manage/v1/config/apply\n```\n\nDisplays the current status of ghe-config-apply in the environment or the status of a historical run by ID.\n\n### Parameters\n\n#### Path and query parameters\n\n* **`run_id`** (string)\n  The unique run ID of the ghe-config-apply run.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/config/apply\n```\n\n**Response schema (Status: 200):**\n\n* `running`: boolean\n* `successful`: boolean\n* `nodes`: array of objects:\n  * `run_id`: string\n  * `hostname`: string\n  * `running`: boolean\n  * `successful`: boolean\n\n## Trigger a ghe-config-apply run\n\n```\nPOST /manage/v1/config/apply\n```\n\nTriggers a run of ghe-config-apply from the ghes-manage agent on your Nomad Delegate instance.\nYou can provide a run ID or allow one to be generated randomly.\n\n### Parameters\n\n#### Body parameters\n\n* **`run_id`** (string)\n  The run ID to execute ghe-config-apply with. If not provided, a run ID will be generated randomly.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X POST \\\n  http(s)://HOSTNAME/manage/v1/config/apply \\\n  -d '{\n  \"run_id\": \"d34db33f\"\n}'\n```\n\n**Response schema (Status: 200):**\n\n* `run_id`: string\n\n## List events from ghe-config-apply\n\n```\nGET /manage/v1/config/apply/events\n```\n\nLists events from an in-process ghe-config-apply run on your Github Enterprise Server instance.\n\n### Parameters\n\n#### Path and query parameters\n\n* **`last_request_id`** (string)\n  The unique ID of the last response from a host, used for pagination.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/config/apply/events\n```\n\n**Response schema (Status: 200):**\n\n* `nodes`: array of objects:\n  * `node`: string\n  * `last_request_id`: string\n  * `events`: array of objects:\n    * `timestamp`: string\n    * `severity_text`: string\n    * `body`: string\n    * `event_name`: string\n    * `topology`: string\n    * `hostname`: string\n    * `config_run_id`: string\n    * `trace_id`: string\n    * `span_id`: string\n    * `span_parent_id`: string\n    * `span_depth`: integer\n\n## Initialize instance configuration with license and password\n\n```\nPOST /manage/v1/config/init\n```\n\nWhen you boot and set up a GitHub instance for the first time, you can use this endpoint to upload a license and set the initial root site administrator password.\nImportant\n\nTo start the configuration process and apply the license, you need to POST to /manage/v1/config/apply\n\nThe root site administrator password provided when calling this endpoint is used to authenticate for all other endpoints in the GHES Manage API and the Management Console UI.\nNote\n\nThe request body for this operation must be submitted as multipart/form-data data. You can can reference the license file by prefixing the filename with the @ symbol using curl. For more information, see the curl documentation.\n\n### Parameters\n\n#### Body parameters\n\n* **`license`** (string) (required)\n  The content of your .ghl license file.\n\n* **`password`** (string) (required)\n  The root site administrator password.\n\n### HTTP response status codes\n\n* **202** - Accepted\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X POST \\\n  http(s)://HOSTNAME/manage/v1/config/init \\\n  -d '{\n  \"license\": \"@enterprise.ghl\",\n  \"password\": \"provide-password-here!\"\n}'\n```\n\n**Response schema (Status: 202):**\n\n## Get the enterprise license information\n\n```\nGET /manage/v1/config/license\n```\n\nGets information about the license that is currently set for the enterprise.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/config/license\n```\n\n**Response schema (Status: 200):**\n\n* `advancedSecurityEnabled`: boolean\n* `advancedSecuritySeats`: integer\n* `clusterSupport`: boolean\n* `company`: string\n* `croquetSupport`: boolean\n* `customTerms`: boolean\n* `evaluation`: boolean\n* `expireAt`: string, format: date-time\n* `insightsEnabled`: boolean\n* `insightsExpireAt`: string, format: date-time\n* `learningLabEvaluationExpires`: string, format: date-time\n* `learningLabSeats`: integer\n* `perpetual`: boolean\n* `referenceNumber`: string\n* `seats`: integer\n* `sshAllowed`: boolean\n* `supportKey`: string\n* `unlimitedSeating`: boolean\n\n## Upload an enterprise license\n\n```\nPUT /manage/v1/config/license\n```\n\nUploads a new enterprise license. In order to apply it right away, use the apply query parameter.\nNote\n\nThe request body for this operation must be submitted as multipart/form-data data. You can can reference the license file by prefixing the filename with the @ symbol using curl. For more information, see the curl documentation.\n\n### Parameters\n\n#### Path and query parameters\n\n* **`apply`** (boolean)\n  Whether to instantly apply changes from the license. Otherwise the new license can be applied using the /manage/v1/config/apply endpoint.\n\n#### Body parameters\n\n* **`license`** (string) (required)\n  The content of your .ghl license file.\n\n### HTTP response status codes\n\n* **201** - Created\n\n* **202** - Accepted\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example 1: Status Code 201\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X PUT \\\n  http(s)://HOSTNAME/manage/v1/config/license \\\n  -d '{\n  \"license\": \"@enterprise.ghl\"\n}'\n```\n\n**Response schema (Status: 201):**\n\n#### Example 2: Status Code 202\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X PUT \\\n  http(s)://HOSTNAME/manage/v1/config/license \\\n  -d '{\n  \"license\": \"@enterprise.ghl\"\n}'\n```\n\n**Response schema (Status: 202):**\n\n## Check a license\n\n```\nGET /manage/v1/config/license/check\n```\n\nCheck the status of the license that is currently set for the enterprise.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/config/license/check\n```\n\n**Response schema (Status: 200):**\n\n* `status`: string, enum: `valid`, `invalid`, `expired`, `cluster mode not supported`\n\n## Get GHES node metadata for all nodes\n\n```\nGET /manage/v1/config/nodes\n```\n\nGet node metadata for all configured nodes in the current cluster. For more information, see \"About clustering.\"\n\n### Parameters\n\n#### Path and query parameters\n\n* **`uuid`** (string)\n  The UUID which identifies a node.\n\n* **`cluster_roles`** (string)\n  The cluster roles from the cluster configuration file.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/config/nodes\n```\n\n**Response schema (Status: 200):**\n\n* `topology`: string, enum: `SingleNode`, `Ha`, `Cluster`\n* `nodes`: array of objects:\n  * `hostname`: string\n  * `uuid`: string\n  * `replica`: boolean\n  * `cluster_roles`: array of string, enum: `Blank`, `ActionsServer`, `ConsulServer`, `ElasticsearchServer`, `GitServer`, `JobServer`, `LaunchServer`, `MemcacheServer`, `MetricsServer`, `MssqlServer`, `MysqlServer`, `PagesServer`, `RedisServer`, `StorageServer`, `WebServer`\n\n## Get the GHES settings\n\n```\nGET /manage/v1/config/settings\n```\n\nGets a list of settings for a GitHub Enterprise Server instance.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/config/settings\n```\n\n**Response schema (Status: 200):**\n\n* `private_mode`: boolean\n* `public_pages`: boolean\n* `subdomain_isolation`: boolean\n* `signup_enabled`: boolean\n* `github_hostname`: string\n* `identicons_host`: string\n* `http_proxy`: string or null\n* `auth_mode`: string\n* `expire_sessions`: boolean\n* `admin_password`: string or null\n* `configuration_id`: integer\n* `configuration_run_count`: integer\n* `avatar`: object:\n  * `enabled`: boolean\n  * `uri`: string\n* `customer`: object:\n  * `name`: string\n  * `email`: string\n  * `uuid`: string\n  * `secret_key_data`: string\n  * `public_key_data`: string\n* `license`: object:\n  * `seats`: integer\n  * `evaluation`: boolean\n  * `perpetual`: boolean\n  * `unlimited_seating`: boolean\n  * `support_key`: string\n  * `ssh_allowed`: boolean\n  * `cluster_support`: boolean\n  * `expire_at`: string\n* `github_ssl`: object:\n  * `enabled`: boolean\n  * `cert`: string or null\n  * `key`: string or null\n* `ldap`: object:\n  * `host`: string or null\n  * `port`: integer\n  * `base`: array of string\n  * `uid`: string or null\n  * `bind_dn`: string or null\n  * `password`: string or null\n  * `method`: string\n  * `search_strategy`: string\n  * `user_groups`: array of string\n  * `admin_group`: string or null\n  * `virtual_attribute_enabled`: boolean\n  * `recursive_group_search`: boolean\n  * `posix_support`: boolean\n  * `user_sync_emails`: boolean\n  * `user_sync_keys`: boolean\n  * `user_sync_interval`: integer\n  * `team_sync_interval`: integer\n  * `sync_enabled`: boolean\n  * `reconciliation`: object:\n    * `user`: string or null\n    * `org`: string or null\n  * `profile`: object:\n    * `uid`: string\n    * `name`: string or null\n    * `mail`: string or null\n    * `key`: string or null\n* `cas`: object:\n  * `url`: string or null\n* `saml`: object:\n  * `sso_url`: string or null\n  * `certificate`: string or null\n  * `certificate_path`: string or null\n  * `issuer`: string or null\n  * `idp_initiated_sso`: boolean\n  * `disable_admin_demote`: boolean\n* `github_oauth`: object:\n  * `client_id`: string\n  * `client_secret`: string\n  * `organization_name`: string\n  * `organization_team`: string\n* `smtp`: object:\n  * `enabled`: boolean\n  * `address`: string\n  * `authentication`: string\n  * `port`: string\n  * `domain`: string\n  * `username`: string\n  * `user_name`: string\n  * `enable_starttls_auto`: boolean\n  * `password`: string\n  * `discard-to-noreply-address`: boolean\n  * `support_address`: string\n  * `support_address_type`: string\n  * `noreply_address`: string\n* `ntp`: object:\n  * `primary_server`: string\n  * `secondary_server`: string\n* `timezone`: string or null\n* `snmp`: object:\n  * `enabled`: boolean\n  * `community`: string\n* `syslog`: object:\n  * `enabled`: boolean\n  * `server`: string or null\n  * `protocol_name`: string\n* `assets`: string or null\n* `pages`: object:\n  * `enabled`: boolean\n* `collectd`: object:\n  * `enabled`: boolean\n  * `server`: string or null\n  * `port`: integer\n  * `encryption`: string or null\n  * `username`: string or null\n  * `password`: string or null\n* `mapping`: object:\n  * `enabled`: boolean\n  * `tileserver`: string or null\n  * `basemap`: string\n  * `token`: string or null\n* `load_balancer`: string or null\n* `prometheus`: object:\n  * `enabled`: boolean\n  * `trusted_ips`: string or null\n\n## Set settings\n\n```\nPUT /manage/v1/config/settings\n```\n\nUpdates the settings on your instance. For a list of the available settings, see the Get settings endpoint.\nNotes:\n\nThe request body only requires the settings parameters that should be updated to be specified, all other parameters will be unmodified or populated from the default values.\nYou cannot set the Management Console root site administrator password with this API endpoint. Use the ghe-set-password utility to change the management console password. For more information, see \"Command-line utilities.\"\n\n### HTTP response status codes\n\n* **204** - No Content\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X PUT \\\n  http(s)://HOSTNAME/manage/v1/config/settings \\\n  -d '{\n  \"public_pages\": true\n}'\n```\n\n**Response schema (Status: 204):**\n\n## Get the status of maintenance mode\n\n```\nGET /manage/v1/maintenance\n```\n\nGets the status and details of maintenance mode on all available nodes. For more information, see \"Enabling and scheduling maintenance mode.\"\n\n### Parameters\n\n#### Path and query parameters\n\n* **`uuid`** (string)\n  The UUID which identifies a node.\n\n* **`cluster_roles`** (string)\n  The cluster roles from the cluster configuration file.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/maintenance\n```\n\n**Response schema (Status: 200):**\n\nArray of objects:\n\n* `hostname`: string, format: hostname\n* `uuid`: string, format: uuid\n* `status`: string, enum: `on`, `off`, `scheduled`\n* `scheduled_time`: string, format: date\n* `connection_services`: array of objects:\n  * `name`: string\n  * `number`: integer\n* `can_unset_maintenance`: boolean\n* `ip_exception_list`: array of string, format: ip/cidr\n* `maintenance_mode_message`: string\n\n## Set the status of maintenance mode\n\n```\nPOST /manage/v1/maintenance\n```\n\nSets or schedules the maintenance mode. For more information, see \"Enabling and scheduling maintenance mode.\"\n\n### Parameters\n\n#### Body parameters\n\n* **`enabled`** (boolean) (required)\n  Whether to enable maintenance mode.\n\n* **`uuid`** (string)\n  The UUID of the node to target. This parameter is incompatible with maintenance mode scheduling. Only use uuid if the value of when is empty or now.\n\n* **`when`** (string)\n  The time to enable maintenance mode. If this parameter is empty or set to now, maintenance mode is enabled immediately. Otherwise, maintenance mode is enabled at the specified time. The format is ISO 8601.\n\n* **`ip_exception_list`** (array of strings)\n  The list of IP addresses to exclude from maintenance mode. IPv4, IPv6, and CIDR addresses are supported.\n\n* **`maintenance_mode_message`** (string)\n  The message to display to users when maintenance mode is enabled.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **400** - Bad request\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X POST \\\n  http(s)://HOSTNAME/manage/v1/maintenance \\\n  -d '{\n  \"enabled\": true,\n  \"when\": \"2006-01-02T15:04:05+00:00\",\n  \"ip_exception_list\": [\n    \"192.168.1.0/24\",\n    \"1.1.1.1\"\n  ]\n}'\n```\n\n**Response schema (Status: 200):**\n\nSame response schema as [Delete a SSH key](#delete-a-ssh-key).\n\n## Get the status of services running on all replica nodes\n\n```\nGET /manage/v1/replication/status\n```\n\nGets the status of all services running on each replica node.\nThis endpoint may take several seconds to reply.\n\n### Parameters\n\n#### Path and query parameters\n\n* **`uuid`** (string)\n  The UUID which identifies a node.\n\n* **`cluster_roles`** (string)\n  The cluster roles from the cluster configuration file.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/replication/status\n```\n\n**Response schema (Status: 200):**\n\nSame response schema as [Get the status of services running on all cluster nodes](#get-the-status-of-services-running-on-all-cluster-nodes).\n\n## Get all GHES release versions for all nodes\n\n```\nGET /manage/v1/version\n```\n\nGets the GitHub Enterprise Server release versions that are currently installed on all available nodes. For more information, see \"GitHub Enterprise Server releases.\"\n\n### Parameters\n\n#### Path and query parameters\n\n* **`uuid`** (string)\n  The UUID which identifies a node.\n\n* **`cluster_roles`** (string)\n  The cluster roles from the cluster configuration file.\n\n### HTTP response status codes\n\n* **200** - OK\n\n* **401** - Unauthorized\n\n* **500** - Internal error\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  http(s)://HOSTNAME/manage/v1/version\n```\n\n**Response schema (Status: 200):**\n\nArray of objects:\n\n* `hostname`: string, format: hostname\n* `version`: object:\n  * `version`: string, pattern: `[0-9]\\.[0-9]{2}\\.[0-9]`\n  * `platform`: string, enum: `ami`, `azure`, `esx`, `gce`, `hyperv`, `kvm`\n  * `build_id`: string, pattern: `[0-9a-f]{8}`\n  * `build_date`: string, format: date"}