Skip to content

Latest commit

 

History

History
222 lines (165 loc) · 6.01 KB

File metadata and controls

222 lines (165 loc) · 6.01 KB

Fastly::DmDomainsApi

require 'fastly'
api_instance = Fastly::DmDomainsApi.new

Methods

Note

All URIs are relative to https://api.fastly.com

Method HTTP request Description
create_dm_domain POST /domain-management/v1/domains Create a domain
delete_dm_domain DELETE /domain-management/v1/domains/{domain_id} Delete a domain
get_dm_domain GET /domain-management/v1/domains/{domain_id} Get a domain
list_dm_domains GET /domain-management/v1/domains List domains
update_dm_domain PATCH /domain-management/v1/domains/{domain_id} Update a domain

create_dm_domain()

create_dm_domain(opts): <SuccessfulResponseAsObject> # Create a domain

Create a domain

Examples

api_instance = Fastly::DmDomainsApi.new
opts = {
    request_body_for_create: Fastly::RequestBodyForCreate.new({fqdn: 'fqdn_example'}), # RequestBodyForCreate | 
}

begin
  # Create a domain
  result = api_instance.create_dm_domain(opts)
  p result
rescue Fastly::ApiError => e
  puts "Error when calling DmDomainsApi->create_dm_domain: #{e}"
end

Options

Name Type Description Notes
request_body_for_create RequestBodyForCreate [optional]

Return type

SuccessfulResponseAsObject

[Back to top] [Back to API list] [Back to README]

delete_dm_domain()

delete_dm_domain(opts) # Delete a domain

Delete a domain

Examples

api_instance = Fastly::DmDomainsApi.new
opts = {
    domain_id: 'domain_id_example', # String | 
}

begin
  # Delete a domain
  api_instance.delete_dm_domain(opts)
rescue Fastly::ApiError => e
  puts "Error when calling DmDomainsApi->delete_dm_domain: #{e}"
end

Options

Name Type Description Notes
domain_id String

Return type

nil (empty response body)

[Back to top] [Back to API list] [Back to README]

get_dm_domain()

get_dm_domain(opts): <SuccessfulResponseAsObject> # Get a domain

Show a domain

Examples

api_instance = Fastly::DmDomainsApi.new
opts = {
    domain_id: 'domain_id_example', # String | 
}

begin
  # Get a domain
  result = api_instance.get_dm_domain(opts)
  p result
rescue Fastly::ApiError => e
  puts "Error when calling DmDomainsApi->get_dm_domain: #{e}"
end

Options

Name Type Description Notes
domain_id String

Return type

SuccessfulResponseAsObject

[Back to top] [Back to API list] [Back to README]

list_dm_domains()

list_dm_domains(opts): <InlineResponse2007> # List domains

List all domains

Examples

api_instance = Fastly::DmDomainsApi.new
opts = {
    fqdn: 'fqdn_example', # String | 
    fqdn_match: 'contains', # String | (Optional) Filter fully-qualified domain name (FQDN) specifically by match type. If used, requires filtering by FQDN.
    service_id: 'service_id_example', # String | Filter results based on a service_id.
    sort: 'fqdn', # String | The order in which to list the results.
    activated: true, # Boolean | 
    verified: true, # Boolean | 
    cursor: 'cursor_example', # String | Cursor value from the `next_cursor` field of a previous response, used to retrieve the next page. To request the first page, this should be empty.
    limit: 56, # Integer | Limit how many results are returned.
}

begin
  # List domains
  result = api_instance.list_dm_domains(opts)
  p result
rescue Fastly::ApiError => e
  puts "Error when calling DmDomainsApi->list_dm_domains: #{e}"
end

Options

Name Type Description Notes
fqdn String [optional]
fqdn_match String (Optional) Filter fully-qualified domain name (FQDN) specifically by match type. If used, requires filtering by FQDN. [optional][default to 'contains']
service_id String Filter results based on a service_id. [optional]
sort String The order in which to list the results. [optional][default to 'fqdn']
activated Boolean [optional]
verified Boolean [optional]
cursor String Cursor value from the next_cursor field of a previous response, used to retrieve the next page. To request the first page, this should be empty. [optional]
limit Integer Limit how many results are returned. [optional][default to 20]

Return type

InlineResponse2007

[Back to top] [Back to API list] [Back to README]

update_dm_domain()

update_dm_domain(opts): <SuccessfulResponseAsObject> # Update a domain

Update a domain

Examples

api_instance = Fastly::DmDomainsApi.new
opts = {
    domain_id: 'domain_id_example', # String | 
    request_body_for_update: Fastly::RequestBodyForUpdate.new, # RequestBodyForUpdate | 
}

begin
  # Update a domain
  result = api_instance.update_dm_domain(opts)
  p result
rescue Fastly::ApiError => e
  puts "Error when calling DmDomainsApi->update_dm_domain: #{e}"
end

Options

Name Type Description Notes
domain_id String
request_body_for_update RequestBodyForUpdate [optional]

Return type

SuccessfulResponseAsObject

[Back to top] [Back to API list] [Back to README]