엔터프라이즈 네트워크 구성을 위한 REST API 엔드포인트
REST API를 사용하여 엔터프라이즈 네트워크 구성과 상호 작용합니다.
List hosted compute network configurations for an enterprise
Lists all hosted compute network configurations configured in an enterprise.
Fine-grained access tokens for "List hosted compute network configurations for an enterprise"
This endpoint does not work with GitHub App user access tokens, GitHub App installation access tokens, or fine-grained personal access tokens.
"List hosted compute network configurations for an enterprise"에 대한 매개 변수
| 이름, 유형, 설명 |
|---|
accept string Setting to |
| 이름, 유형, 설명 |
|---|
enterprise string 필수The slug version of the enterprise name. |
| 이름, 유형, 설명 |
|---|
per_page integer The number of results per page (max 100). For more information, see "Using pagination in the REST API." 기본값: |
page integer The page number of the results to fetch. For more information, see "Using pagination in the REST API." 기본값: |
HTTP response status codes for "List hosted compute network configurations for an enterprise"
| Status code | 설명 |
|---|---|
200 | OK |
Code samples for "List hosted compute network configurations for an enterprise"
If you access GitHub at GHE.com, replace api.github.com with your enterprise's dedicated subdomain at api.SUBDOMAIN.ghe.com.
Request example
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2026-03-10" \
https://api.github.com/enterprises/ENTERPRISE/network-configurationsResponse
Status: 200{
"total_count": 2,
"network_configurations": [
{
"id": "123456789ABCDEF",
"name": "My network configuration",
"compute_service": "actions",
"network_settings_ids": [
"23456789ABDCEF1",
"3456789ABDCEF12"
],
"created_on": "2022-10-09T23:39:01Z"
},
{
"id": "456789ABDCEF123",
"name": "My other configuration",
"compute_service": "none",
"network_settings_ids": [
"56789ABDCEF1234",
"6789ABDCEF12345"
],
"created_on": "2023-04-26T15:23:37Z"
}
]
}Create a hosted compute network configuration for an enterprise
Creates a hosted compute network configuration for an enterprise.
Fine-grained access tokens for "Create a hosted compute network configuration for an enterprise"
This endpoint does not work with GitHub App user access tokens, GitHub App installation access tokens, or fine-grained personal access tokens.
"Create a hosted compute network configuration for an enterprise"에 대한 매개 변수
| 이름, 유형, 설명 |
|---|
accept string Setting to |
| 이름, 유형, 설명 |
|---|
enterprise string 필수The slug version of the enterprise name. |
| 이름, 유형, 설명 |
|---|
name string 필수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, |
compute_service string The hosted compute service to use for the network configuration. 다음 중 하나일 수 있습니다.: |
network_settings_ids array of strings 필수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. |
failover_network_settings_ids array of strings 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. |
failover_network_enabled boolean Indicates whether the failover network resource is enabled. |
HTTP response status codes for "Create a hosted compute network configuration for an enterprise"
| Status code | 설명 |
|---|---|
201 | Created |
Code samples for "Create a hosted compute network configuration for an enterprise"
If you access GitHub at GHE.com, replace api.github.com with your enterprise's dedicated subdomain at api.SUBDOMAIN.ghe.com.
Request example
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2026-03-10" \
https://api.github.com/enterprises/ENTERPRISE/network-configurations \
-d '{"name":"my-network-configuration","network_settings_ids":["23456789ABDCEF1"],"compute_service":"actions"}'Response
Status: 201{
"id": "123456789ABCDEF",
"name": "My network configuration",
"compute_service": "actions",
"network_settings_ids": [
"23456789ABDCEF1",
"3456789ABDCEF12"
],
"created_on": "2022-10-09T23:39:01Z"
}Get a hosted compute network configuration for an enterprise
Gets a hosted compute network configuration configured in an enterprise.
Fine-grained access tokens for "Get a hosted compute network configuration for an enterprise"
This endpoint does not work with GitHub App user access tokens, GitHub App installation access tokens, or fine-grained personal access tokens.
"Get a hosted compute network configuration for an enterprise"에 대한 매개 변수
| 이름, 유형, 설명 |
|---|
accept string Setting to |
| 이름, 유형, 설명 |
|---|
enterprise string 필수The slug version of the enterprise name. |
network_configuration_id string 필수Unique identifier of the hosted compute network configuration. |
HTTP response status codes for "Get a hosted compute network configuration for an enterprise"
| Status code | 설명 |
|---|---|
200 | OK |
Code samples for "Get a hosted compute network configuration for an enterprise"
If you access GitHub at GHE.com, replace api.github.com with your enterprise's dedicated subdomain at api.SUBDOMAIN.ghe.com.
Request example
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2026-03-10" \
https://api.github.com/enterprises/ENTERPRISE/network-configurations/NETWORK_CONFIGURATION_IDResponse
Status: 200{
"id": "123456789ABCDEF",
"name": "My network configuration",
"compute_service": "actions",
"network_settings_ids": [
"23456789ABDCEF1",
"3456789ABDCEF12"
],
"created_on": "2022-10-09T23:39:01Z"
}Update a hosted compute network configuration for an enterprise
Updates a hosted compute network configuration for an enterprise.
Fine-grained access tokens for "Update a hosted compute network configuration for an enterprise"
This endpoint does not work with GitHub App user access tokens, GitHub App installation access tokens, or fine-grained personal access tokens.
"Update a hosted compute network configuration for an enterprise"에 대한 매개 변수
| 이름, 유형, 설명 |
|---|
accept string Setting to |
| 이름, 유형, 설명 |
|---|
enterprise string 필수The slug version of the enterprise name. |
network_configuration_id string 필수Unique identifier of the hosted compute network configuration. |
| 이름, 유형, 설명 |
|---|
name string 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, |
compute_service string The hosted compute service to use for the network configuration. 다음 중 하나일 수 있습니다.: |
network_settings_ids array of strings 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. |
failover_network_settings_ids array of strings 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. |
failover_network_enabled boolean Indicates whether the failover network resource is enabled. |
HTTP response status codes for "Update a hosted compute network configuration for an enterprise"
| Status code | 설명 |
|---|---|
200 | OK |
Code samples for "Update a hosted compute network configuration for an enterprise"
If you access GitHub at GHE.com, replace api.github.com with your enterprise's dedicated subdomain at api.SUBDOMAIN.ghe.com.
Request example
curl -L \
-X PATCH \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2026-03-10" \
https://api.github.com/enterprises/ENTERPRISE/network-configurations/NETWORK_CONFIGURATION_ID \
-d '{"name":"my-network-configuration","network_settings_ids":["23456789ABDCEF1"],"compute_service":"actions"}'Response
Status: 200{
"id": "123456789ABCDEF",
"name": "My network configuration",
"compute_service": "actions",
"network_settings_ids": [
"23456789ABDCEF1",
"3456789ABDCEF12"
],
"created_on": "2022-10-09T23:39:01Z"
}Delete a hosted compute network configuration from an enterprise
Deletes a hosted compute network configuration from an enterprise.
Fine-grained access tokens for "Delete a hosted compute network configuration from an enterprise"
This endpoint does not work with GitHub App user access tokens, GitHub App installation access tokens, or fine-grained personal access tokens.
"Delete a hosted compute network configuration from an enterprise"에 대한 매개 변수
| 이름, 유형, 설명 |
|---|
accept string Setting to |
| 이름, 유형, 설명 |
|---|
enterprise string 필수The slug version of the enterprise name. |
network_configuration_id string 필수Unique identifier of the hosted compute network configuration. |
HTTP response status codes for "Delete a hosted compute network configuration from an enterprise"
| Status code | 설명 |
|---|---|
204 | No Content |
Code samples for "Delete a hosted compute network configuration from an enterprise"
If you access GitHub at GHE.com, replace api.github.com with your enterprise's dedicated subdomain at api.SUBDOMAIN.ghe.com.
Request example
curl -L \
-X DELETE \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2026-03-10" \
https://api.github.com/enterprises/ENTERPRISE/network-configurations/NETWORK_CONFIGURATION_IDResponse
Status: 204Get a hosted compute network settings resource for an enterprise
Gets a hosted compute network settings resource configured for an enterprise.
Fine-grained access tokens for "Get a hosted compute network settings resource for an enterprise"
This endpoint does not work with GitHub App user access tokens, GitHub App installation access tokens, or fine-grained personal access tokens.
"Get a hosted compute network settings resource for an enterprise"에 대한 매개 변수
| 이름, 유형, 설명 |
|---|
accept string Setting to |
| 이름, 유형, 설명 |
|---|
enterprise string 필수The slug version of the enterprise name. |
network_settings_id string 필수Unique identifier of the hosted compute network settings. |
HTTP response status codes for "Get a hosted compute network settings resource for an enterprise"
| Status code | 설명 |
|---|---|
200 | OK |
Code samples for "Get a hosted compute network settings resource for an enterprise"
If you access GitHub at GHE.com, replace api.github.com with your enterprise's dedicated subdomain at api.SUBDOMAIN.ghe.com.
Request example
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2026-03-10" \
https://api.github.com/enterprises/ENTERPRISE/network-settings/NETWORK_SETTINGS_IDResponse
Status: 200{
"id": "220F78DACB92BBFBC5E6F22DE1CCF52309D",
"network_configuration_id": "934E208B3EE0BD60CF5F752C426BFB53562",
"name": "my_network_settings",
"subnet_id": "/subscriptions/14839728-3ad9-43ab-bd2b-fa6ad0f75e2a/resourceGroups/my-rg/providers/Microsoft.Network/virtualNetworks/my-vnet/subnets/my-subnet",
"region": "eastus"
}