Skip to content

Replace API Discovery.

PUT
/api/config/namespaces/{metadata.namespace}/api_discoverys/{metadata.name}
curl --request PUT \
--url https://example-corp.console.ves.volterra.io/api/v1/api/production/us-east-1/namespaces/default/api/config/namespaces/example/api_discoverys/example \
--header 'Authorization: <Authorization>' \
--header 'Content-Type: application/json' \
--data '{ "metadata": { "annotations": {}, "description": "example", "disable": true, "labels": {}, "name": "example", "namespace": "example" }, "spec": { "custom_auth_types": [], "user_defined_api_discovery_policy": { "discovery_rules": [], "exclusive": { "archive": {}, "ignore": {} }, "inclusive": {} } }, "resource_version": "example" }'

Replace api_discovery replaces an existing object in the storage backend for metadata.namespace.

Examples of this operation.

metadata.namespace
required
string

Namespace This defines the workspace within which each the configuration object is to be created. Must be a DNS_LABEL format. For a namespace object itself, namespace value will be “”

metadata.name
required
string

Name The configuration object to be replaced will be looked up by name.

Media typeapplication/json
ReplaceRequest is used to replace contents of a api_discovery

This is the input message of the ‘Replace’ RPC.

object
metadata
object
annotations
annotations

Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects.

object
description
description

Human readable description for the object.

string
>= 21 characters <= 1200 characters
disable
disable

A value of true will administratively disable the object.

boolean format: boolean
labels
labels

Map of string keys and values that can be used to organize and categorize (scope and select) objects as chosen by the user. Values specified here will be used by selector expression.

object
name
name

This is the name of configuration object. It has to be unique within the namespace. It can only be specified during create API and cannot be changed during replace API. The value of name has to follow DNS-1035 format.

string
>= 1 characters <= 63 characters /^[a-z]([-a-z0-9]*[a-z0-9])?$/
namespace
namespace

This defines the workspace within which each the configuration object is to be created. Must be a DNS_LABEL format. For a namespace object itself, namespace value will be “”

string
>= 1 characters <= 63 characters /^[a-z]([-a-z0-9]*[a-z0-9])?$/
spec
object
custom_auth_types

Select your custom authentication types to be detected in the API discovery.

Array<object>
default: <= 10 items
CustomAuthType

Customize Authentication Type.

object
parameter_name
parameter name

The authentication parameter name.

string
<= 256 characters
parameter_type
string
default: QUERY_PARAMETER
Allowed values: QUERY_PARAMETER HEADER COOKIE
user_defined_api_discovery_policy
object
discovery_rules
discovery_rules

Define rules to include or exclude endpoints by path, domain, or header. Rules run top to bottom; unmatched endpoints follow the default action.

Array<object>
default: <= 100 items
DiscoveryRule

Defines a rule for classifying endpoints as API or Non-API.

object
labels
labels

Map of string keys and values that can be used to organize and categorize the rule.

object
metadata
object
description
description

Human readable description.

string
>= 21 characters <= 256 characters
name
name

This is the name of the message. The value of name has to follow DNS-1035 format.

string
>= 1 characters <= 63 characters /^[a-z]([-a-z0-9]*[a-z0-9])?$/
rule_properties
object
exclusion
object
archive
object
ignore
object
http_header_criteria
object
field_name
field_name

Human-readable name for the resource

string
<= 256 characters
location
string
default: REQUEST
Allowed values: REQUEST RESPONSE
match_type
string
default: EXACT_MATCH
Allowed values: EXACT_MATCH SUBSTRING REGEX
value
value

Configuration parameter for value

string
>= 3 characters <= 1024 characters
inclusion
object
pattern
pattern

Exclusive with [http_header_criteria] Patterns are matched against the request path to identify endpoints by path structure, file extension, or version prefix. Endpoints that match this pattern are affected by the rule.

string
<= 512 characters
exclusive
object
archive
object
ignore
object
inclusive
object
resource_version
string

A successful response.

Media typeapplication/json
object
Examplegenerated
{}

Returned when operation is not authorized.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when there is no permission to access resource.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when resource is not found.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when operation on resource is conflicting with current value.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when operation has been rejected as it is happening too frequently.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when server encountered an error in processing API.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when service is unavailable temporarily.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when server timed out processing request.

Media typeapplication/json
string format: string
Examplegenerated
example