{"meta":{"title":"Points d'extrémité de l'API REST pour les configurations de réseau","intro":"Points d'extrémité de l'API REST pour les configurations de réseau","product":"API REST","breadcrumbs":[{"href":"/fr/enterprise-cloud@latest/rest","title":"API REST"},{"href":"/fr/enterprise-cloud@latest/rest/orgs","title":"Organisations"},{"href":"/fr/enterprise-cloud@latest/rest/orgs/network-configurations","title":"Configurations réseau"}],"documentType":"article"},"body":"# Points d'extrémité de l'API REST pour les configurations de réseau\n\nPoints d'extrémité de l'API REST pour les configurations de réseau\n\n> [!NOTE]\n> Most endpoints use `Authorization: Bearer <YOUR-TOKEN>` and `Accept: application/vnd.github+json` headers, plus `X-GitHub-Api-Version: 2026-03-10`. Curl examples below omit these standard headers for brevity.\n\n## List hosted compute network configurations for an organization\n\n```\nGET /orgs/{org}/settings/network-configurations\n```\n\nLists all hosted compute network configurations configured in an organization.\nOAuth app tokens and personal access tokens (classic) need the read:network_configurations scope to use this endpoint.\n\n### Parameters\n\n#### Headers\n\n- **`accept`** (string)\n  Setting to `application/vnd.github+json` is recommended.\n\n#### Path and query parameters\n\n- **`org`** (string) (required)\n  The organization name. The name is not case sensitive.\n\n- **`per_page`** (integer)\n  The number of results per page (max 100). For more information, see \"Using pagination in the REST API.\"\n  Default: `30`\n\n- **`page`** (integer)\n  The page number of the results to fetch. For more information, see \"Using pagination in the REST API.\"\n  Default: `1`\n\n### HTTP response status codes\n\n- **200** - OK\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  https://api.github.com/orgs/ORG/settings/network-configurations\n```\n\n**Response schema (Status: 200):**\n\n* `total_count`: required, integer\n* `network_configurations`: required, array of `Hosted compute network configuration`:\n  * `id`: required, string\n  * `name`: required, string\n  * `compute_service`: string, enum: `none`, `actions`, `codespaces`\n  * `network_settings_ids`: array of string\n  * `failover_network_settings_ids`: array of string\n  * `failover_network_enabled`: boolean\n  * `created_on`: required, string or null, format: date-time\n\n## Create a hosted compute network configuration for an organization\n\n```\nPOST /orgs/{org}/settings/network-configurations\n```\n\nCreates a hosted compute network configuration for an organization.\nOAuth app tokens and personal access tokens (classic) need the write:network_configurations scope to use this endpoint.\n\n### Parameters\n\n#### Headers\n\n- **`accept`** (string)\n  Setting to `application/vnd.github+json` is recommended.\n\n#### Path and query parameters\n\n- **`org`** (string) (required)\n  The organization name. The name is not case sensitive.\n\n#### Body parameters\n\n- **`name`** (string) (required)\n  Name of the network configuration. Must be between 1 and 100 characters and may only contain upper and lowercase letters a-z, numbers 0-9, '.', '-', and '_'.\n\n- **`compute_service`** (string)\n  The hosted compute service to use for the network configuration.\n  Can be one of: `none`, `actions`\n\n- **`network_settings_ids`** (array of strings) (required)\n  A list of identifiers of the network settings resources to use for the network configuration. Exactly one resource identifier must be specified in the list.\n\n- **`failover_network_settings_ids`** (array of strings)\n  A list of identifiers of the failover network settings resources to use for the network configuration. Exactly one resource identifier must be specified in the list.\n\n- **`failover_network_enabled`** (boolean)\n  Indicates whether the failover network resource is enabled.\n\n### HTTP response status codes\n\n- **201** - Created\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X POST \\\n  https://api.github.com/orgs/ORG/settings/network-configurations \\\n  -d '{\n  \"name\": \"my-network-configuration\",\n  \"network_settings_ids\": [\n    \"23456789ABDCEF1\"\n  ],\n  \"compute_service\": \"actions\"\n}'\n```\n\n**Response schema (Status: 201):**\n\n* `id`: required, string\n* `name`: required, string\n* `compute_service`: string, enum: `none`, `actions`, `codespaces`\n* `network_settings_ids`: array of string\n* `failover_network_settings_ids`: array of string\n* `failover_network_enabled`: boolean\n* `created_on`: required, string or null, format: date-time\n\n## Get a hosted compute network configuration for an organization\n\n```\nGET /orgs/{org}/settings/network-configurations/{network_configuration_id}\n```\n\nGets a hosted compute network configuration configured in an organization.\nOAuth app tokens and personal access tokens (classic) need the read:network_configurations scope to use this endpoint.\n\n### Parameters\n\n#### Headers\n\n- **`accept`** (string)\n  Setting to `application/vnd.github+json` is recommended.\n\n#### Path and query parameters\n\n- **`org`** (string) (required)\n  The organization name. The name is not case sensitive.\n\n- **`network_configuration_id`** (string) (required)\n  Unique identifier of the hosted compute network configuration.\n\n### HTTP response status codes\n\n- **200** - OK\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  https://api.github.com/orgs/ORG/settings/network-configurations/NETWORK_CONFIGURATION_ID\n```\n\n**Response schema (Status: 200):**\n\nSame response schema as [Create a hosted compute network configuration for an organization](#create-a-hosted-compute-network-configuration-for-an-organization).\n\n## Update a hosted compute network configuration for an organization\n\n```\nPATCH /orgs/{org}/settings/network-configurations/{network_configuration_id}\n```\n\nUpdates a hosted compute network configuration for an organization.\nOAuth app tokens and personal access tokens (classic) need the write:network_configurations scope to use this endpoint.\n\n### Parameters\n\n#### Headers\n\n- **`accept`** (string)\n  Setting to `application/vnd.github+json` is recommended.\n\n#### Path and query parameters\n\n- **`org`** (string) (required)\n  The organization name. The name is not case sensitive.\n\n- **`network_configuration_id`** (string) (required)\n  Unique identifier of the hosted compute network configuration.\n\n#### Body parameters\n\n- **`name`** (string)\n  Name of the network configuration. Must be between 1 and 100 characters and may only contain upper and lowercase letters a-z, numbers 0-9, '.', '-', and '_'.\n\n- **`compute_service`** (string)\n  The hosted compute service to use for the network configuration.\n  Can be one of: `none`, `actions`\n\n- **`network_settings_ids`** (array of strings)\n  A list of identifiers of the network settings resources to use for the network configuration. Exactly one resource identifier must be specified in the list.\n\n- **`failover_network_settings_ids`** (array of strings)\n  A list of identifiers of the failover network settings resources to use for the network configuration. Exactly one resource identifier must be specified in the list.\n\n- **`failover_network_enabled`** (boolean)\n  Indicates whether the failover network resource is enabled.\n\n### HTTP response status codes\n\n- **200** - OK\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X PATCH \\\n  https://api.github.com/orgs/ORG/settings/network-configurations/NETWORK_CONFIGURATION_ID \\\n  -d '{\n  \"name\": \"my-network-configuration\",\n  \"network_settings_ids\": [\n    \"23456789ABDCEF1\"\n  ],\n  \"compute_service\": \"actions\"\n}'\n```\n\n**Response schema (Status: 200):**\n\nSame response schema as [Create a hosted compute network configuration for an organization](#create-a-hosted-compute-network-configuration-for-an-organization).\n\n## Delete a hosted compute network configuration from an organization\n\n```\nDELETE /orgs/{org}/settings/network-configurations/{network_configuration_id}\n```\n\nDeletes a hosted compute network configuration from an organization.\nOAuth app tokens and personal access tokens (classic) need the write:network_configurations scope to use this endpoint.\n\n### Parameters\n\n#### Headers\n\n- **`accept`** (string)\n  Setting to `application/vnd.github+json` is recommended.\n\n#### Path and query parameters\n\n- **`org`** (string) (required)\n  The organization name. The name is not case sensitive.\n\n- **`network_configuration_id`** (string) (required)\n  Unique identifier of the hosted compute network configuration.\n\n### HTTP response status codes\n\n- **204** - No Content\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X DELETE \\\n  https://api.github.com/orgs/ORG/settings/network-configurations/NETWORK_CONFIGURATION_ID\n```\n\n**Response schema (Status: 204):**\n\n## Get a hosted compute network settings resource for an organization\n\n```\nGET /orgs/{org}/settings/network-settings/{network_settings_id}\n```\n\nGets a hosted compute network settings resource configured for an organization.\nOAuth app tokens and personal access tokens (classic) need the read:network_configurations scope to use this endpoint.\n\n### Parameters\n\n#### Headers\n\n- **`accept`** (string)\n  Setting to `application/vnd.github+json` is recommended.\n\n#### Path and query parameters\n\n- **`org`** (string) (required)\n  The organization name. The name is not case sensitive.\n\n- **`network_settings_id`** (string) (required)\n  Unique identifier of the hosted compute network settings.\n\n### HTTP response status codes\n\n- **200** - OK\n\n### Code examples\n\n#### Example\n\n**Request:**\n\n```curl\ncurl -L \\\n  -X GET \\\n  https://api.github.com/orgs/ORG/settings/network-settings/NETWORK_SETTINGS_ID\n```\n\n**Response schema (Status: 200):**\n\n* `id`: required, string\n* `network_configuration_id`: string\n* `name`: required, string\n* `subnet_id`: required, string\n* `region`: required, string"}