diff options
Diffstat (limited to 'api-ref/source')
-rw-r--r-- | api-ref/source/dns-api-v2-index.rst | 1 | ||||
-rw-r--r-- | api-ref/source/dns-api-v2-shared-zones.inc | 215 | ||||
-rw-r--r-- | api-ref/source/dns-api-v2-zone.inc | 6 | ||||
-rw-r--r-- | api-ref/source/parameters.yaml | 49 | ||||
-rw-r--r-- | api-ref/source/samples/zones/list-share-zone-response.json | 28 | ||||
-rw-r--r-- | api-ref/source/samples/zones/share-zone-request.json | 3 | ||||
-rw-r--r-- | api-ref/source/samples/zones/share-zone-response.json | 12 |
7 files changed, 314 insertions, 0 deletions
diff --git a/api-ref/source/dns-api-v2-index.rst b/api-ref/source/dns-api-v2-index.rst index 0bce803f..b4a6be95 100644 --- a/api-ref/source/dns-api-v2-index.rst +++ b/api-ref/source/dns-api-v2-index.rst @@ -10,6 +10,7 @@ .. include:: dns-api-v2-zone-import.inc .. include:: dns-api-v2-zone-export.inc .. include:: dns-api-v2-zone-tasks.inc +.. include:: dns-api-v2-shared-zones.inc .. include:: dns-api-v2-zone-ownership-transfer-request.inc .. include:: dns-api-v2-zone-ownership-transfer-accept.inc .. include:: dns-api-v2-recordset.inc diff --git a/api-ref/source/dns-api-v2-shared-zones.inc b/api-ref/source/dns-api-v2-shared-zones.inc new file mode 100644 index 00000000..8f6853f0 --- /dev/null +++ b/api-ref/source/dns-api-v2-shared-zones.inc @@ -0,0 +1,215 @@ +============ +Shared Zones +============ + +Shared zones operations. + + +Show a Zone Share +================= + +.. rest_method:: GET /v2/zones/{zone_id}/shares/{zone_share_id} + +Show a single zone share. + +**New in version 2.1** + +.. rest_status_code:: success status.yaml + + - 200 + +.. rest_status_code:: error status.yaml + + - 400 + - 401 + - 403 + - 404 + - 405 + - 500 + - 503 + +Request +------- + +.. rest_parameters:: parameters.yaml + + - x-auth-token: x-auth-token + - x-auth-all-projects: x-auth-all-projects + - x-auth-sudo-project-id: x-auth-sudo-project-id + - zone_id: path_zone_id + - zone_share_id: path_zone_share_id + +Response Parameters +------------------- + +.. rest_parameters:: parameters.yaml + + - x-openstack-request-id: x-openstack-request-id + - id: id + - zone_id: shared_zone_id + - project_id: project_id + - target_project_id: target_project_id + - created_at: created_at + - updated_at: updated_at + - links: links + +Response Example +---------------- + +.. literalinclude:: samples/zones/share-zone-response.json + +Get All Shared Zones +==================== + +.. rest_method:: GET /v2/zones/{zone_id}/shares + +List all zone shares. + +**New in version 2.1** + +.. rest_status_code:: success status.yaml + + - 200 + +.. rest_status_code:: error status.yaml + + - 400 + - 401 + - 403 + - 404 + - 405 + - 500 + - 503 + + +Request +------- + +.. rest_parameters:: parameters.yaml + + - x-auth-token: x-auth-token + - x-auth-all-projects: x-auth-all-projects + - x-auth-sudo-project-id: x-auth-sudo-project-id + - zone_id: path_zone_id + - target_project_id: target_project_id_filter + +Response Parameters +------------------- + +.. rest_parameters:: parameters.yaml + + - x-openstack-request-id: x-openstack-request-id + - id: id + - zone_id: shared_zone_id + - project_id: project_id + - target_project_id: target_project_id + - created_at: created_at + - updated_at: updated_at + - links: links + +Response Example +---------------- + +.. literalinclude:: samples/zones/list-share-zone-response.json + + +Create Shared Zone +================== + +.. rest_method:: POST /v2/zones/{zone_id}/shares + +Share a zone with another project. + +**New in version 2.1** + +.. rest_status_code:: success status.yaml + + - 201 + +.. rest_status_code:: error status.yaml + + - 400 + - 401 + - 403 + - 404 + - 405 + - 409 + - 500 + - 503 + +Request +------- + +.. rest_parameters:: parameters.yaml + + - x-auth-token: x-auth-token + - x-auth-all-projects: x-auth-all-projects + - x-auth-sudo-project-id: x-auth-sudo-project-id + - zone_id: path_zone_id + - target_project_id: target_project_id + +Request Example +--------------- + +.. literalinclude:: samples/zones/share-zone-request.json + +Response Parameters +------------------- + +.. rest_parameters:: parameters.yaml + + - x-openstack-request-id: x-openstack-request-id + - id: id + - zone_id: shared_zone_id + - project_id: project_id + - target_project_id: target_project_id + - created_at: created_at + - updated_at: updated_at + - links: links + +Response Example +---------------- + +.. literalinclude:: samples/zones/share-zone-response.json + + +Delete a Zone Share +=================== + +.. rest_method:: DELETE /v2/zones/{zone_id}/shares/{zone_share_id} + +Delete a zone share. + +**New in version 2.1** + +.. rest_status_code:: success status.yaml + + - 204 + +.. rest_status_code:: error status.yaml + + - 400 + - 401 + - 403 + - 404 + - 405 + - 500 + - 503 + +Request +------- + +.. rest_parameters:: parameters.yaml + + - x-auth-token: x-auth-token + - x-auth-all-projects: x-auth-all-projects + - x-auth-sudo-project-id: x-auth-sudo-project-id + - zone_id: path_zone_id + - zone_share_id: path_zone_share_id + +Response Parameters +------------------- + +.. rest_parameters:: parameters.yaml + + - x-openstack-request-id: x-openstack-request-id diff --git a/api-ref/source/dns-api-v2-zone.inc b/api-ref/source/dns-api-v2-zone.inc index e99a095d..8a68a2b4 100644 --- a/api-ref/source/dns-api-v2-zone.inc +++ b/api-ref/source/dns-api-v2-zone.inc @@ -75,6 +75,7 @@ Response Parameters - created_at: created_at - updated_at: updated_at - attributes: zone_attributes + - shared: shared - links: links @@ -152,6 +153,7 @@ Response Parameters - created_at: created_at - updated_at: updated_at - attributes: zone_attributes + - shared: shared - links: links - metadata: metadata @@ -221,6 +223,7 @@ Response Parameters - created_at: created_at - updated_at: updated_at - attributes: zone_attributes + - shared: shared - links: links @@ -352,6 +355,7 @@ Response Parameters - created_at: created_at - updated_at: updated_at - attributes: zone_attributes + - shared: shared - links: links @@ -395,6 +399,7 @@ Request - x-auth-all-projects: x-auth-all-projects - x-auth-sudo-project-id: x-auth-sudo-project-id - x-designate-hard-delete: x-designate-hard-delete + - x-designate-delete-shares: x-designate-delete-shares - zone_id: path_zone_id @@ -421,6 +426,7 @@ Response Parameters - created_at: created_at - updated_at: updated_at - attributes: zone_attributes + - shared: shared - links: links diff --git a/api-ref/source/parameters.yaml b/api-ref/source/parameters.yaml index ef463af8..ba7aa4e9 100644 --- a/api-ref/source/parameters.yaml +++ b/api-ref/source/parameters.yaml @@ -23,6 +23,14 @@ x-auth-token: required: false type: string +x-designate-delete-shares: + description: | + If enabled, this will delete associated shares along with the resource. + in: header + required: false + type: bool + min_version: 2.1 + x-designate-edit-managed-records: description: | If enabled this will all users to edit records flagged as managed @@ -121,6 +129,14 @@ path_zone_import_id: required: true type: uuid +path_zone_share_id: + description: | + ID of the zone share. + in: path + required: true + type: uuid + min_version: 2.1 + path_zone_transfer_accept_id: description: | ID for this zone transfer accept @@ -255,6 +271,15 @@ sort_key: required: false type: string +target_project_id_filter: + description: | + Filter results to only show resources that have a matching + target_project_id + in: query + required: false + type: string + min_version: 2.1 + tld_name_filter: description: | Filter results to only show tlds that have a name matching the filter @@ -691,6 +716,22 @@ service_statuses: required: true type: array +shared: + description: | + True if the zone is shared with another project. + in: body + required: true + type: bool + min_version: 2.1 + +shared_zone_id: + description: | + ID for the zone being shared. + in: body + required: true + type: uuid + min_version: 2.1 + stats: description: | Statistics for the service. @@ -705,6 +746,14 @@ status: required: true type: enum +target_project_id: + description: | + The project ID the zone will be shared with. + in: body + required: true + type: string + min_version: 2.1 + tld_description: description: | Description for this tld diff --git a/api-ref/source/samples/zones/list-share-zone-response.json b/api-ref/source/samples/zones/list-share-zone-response.json new file mode 100644 index 00000000..c3b5ee3a --- /dev/null +++ b/api-ref/source/samples/zones/list-share-zone-response.json @@ -0,0 +1,28 @@ +{ + "shared_zones": [{ + "id": "4495ffbb-b7d1-43e0-9423-f0a4172e5f9e", + "zone_id": "a3365b47-ee93-43ad-9a60-2b2ca96b1898", + "project_id": "16ade46c85a1435bb86d9138d37da57e", + "target_project_id": "232e37df46af42089710e2ae39111c2f", + "created_at": "2022-12-01T23:02:49.000000", + "updated_at": null, + "links": { + "self": "http://127.0.0.1:60053/v2/zones/a3365b47-ee93-43ad-9a60-2b2ca96b1898/shares/4495ffbb-b7d1-43e0-9423-f0a4172e5f9e", + "zone": "http://127.0.0.1:60053/v2/zones/a3365b47-ee93-43ad-9a60-2b2ca96b1898" + } + }, { + "id": "1f278d08-2f6a-462a-bb49-21a4f6e6d32b", + "zone_id": "a3365b47-ee93-43ad-9a60-2b2ca96b1898", + "project_id": "16ade46c85a1435bb86d9138d37da57e", + "target_project_id": "86d78e93698e4b06aad4f62e04afb4c1", + "created_at": "2022-12-02T01:51:48.000000", + "updated_at": null, + "links": { + "self": "http://127.0.0.1:60053/v2/zones/a3365b47-ee93-43ad-9a60-2b2ca96b1898/shares/1f278d08-2f6a-462a-bb49-21a4f6e6d32b", + "zone": "http://127.0.0.1:60053/v2/zones/a3365b47-ee93-43ad-9a60-2b2ca96b1898" + } + }], + "links": { + "self": "http://127.0.0.1:60053/v2/zones/a3365b47-ee93-43ad-9a60-2b2ca96b1898/shares" + } +} diff --git a/api-ref/source/samples/zones/share-zone-request.json b/api-ref/source/samples/zones/share-zone-request.json new file mode 100644 index 00000000..c3442cf5 --- /dev/null +++ b/api-ref/source/samples/zones/share-zone-request.json @@ -0,0 +1,3 @@ +{ + "target_project_id": "232e37df46af42089710e2ae39111c2f" +} diff --git a/api-ref/source/samples/zones/share-zone-response.json b/api-ref/source/samples/zones/share-zone-response.json new file mode 100644 index 00000000..ff513c86 --- /dev/null +++ b/api-ref/source/samples/zones/share-zone-response.json @@ -0,0 +1,12 @@ +{ + "id": "fd40b017-bf97-461c-8d30-d4e922b28edd", + "zone_id": "a3365b47-ee93-43ad-9a60-2b2ca96b1898", + "project_id": "16ade46c85a1435bb86d9138d37da57e", + "target_project_id": "232e37df46af42089710e2ae39111c2f", + "created_at": "2022-11-30T22:20:27.000000", + "updated_at": null, + "links": { + "self": "http://127.0.0.1:60053/v2/zones/a3365b47-ee93-43ad-9a60-2b2ca96b1898/shares/fd40b017-bf97-461c-8d30-d4e922b28edd", + "zone": "http://127.0.0.1:60053/v2/zones/a3365b47-ee93-43ad-9a60-2b2ca96b1898" + } +} |