{"openapi":"3.0.1","info":{"title":"API7 Enterprise Admin APIs","description":"API7 Enterprise Admin APIs are RESTful APIs that allow you to create and manage API7 resources. ","version":"3.7.2"},"servers":[],"security":[{"APIKeyAuth":[]},{"BasicAuth":[]}],"paths":{"/apisix/admin/services":{"post":{"tags":["Published Service"],"summary":"Create a published service on a gateway group.","operationId":"createPublishedService","description":"IAM Action: `gateway:CreatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/*`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"allOf":[{"oneOf":[{"title":"HTTP","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}},{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["http"]},"hosts":{"type":"array","description":"The hosts for the service to accept incoming requests.","uniqueItems":true,"minItems":1,"maxItems":32,"items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"path_prefix":{"maxLength":4096,"minLength":1,"pattern":"^/","type":"string","description":"The listening path prefix of the service."},"strip_path_prefix":{"type":"boolean","default":true,"description":"Weather strip the path prefix or not when proxying the request to the upstream."},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]}}}]},{"title":"Stream","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}},{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["stream"]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}}}]}]},{"type":"object","properties":{"status":{"default":1,"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Published Service"],"summary":"List all published services on a gateway group.","operationId":"listPublishedServices","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","last_published","name"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"runtime_type","in":"query","schema":{"type":"string","enum":["normal","canary"]}},{"name":"unhealthy_nodes","in":"query","schema":{"type":"array","items":{"type":"string","enum":["unhealthy_nodes_exists","no_unhealthy_nodes"]}}},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"hosts","in":"query","schema":{"type":"array","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}}},{"name":"type","in":"query","schema":{"type":"array","items":{"type":"string","enum":["http","stream"]}}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of services.","items":{"allOf":[{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/services/{service_id}":{"get":{"tags":["Published Service"],"summary":"Get a published service on a gateway group.","operationId":"getPublishedService","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Published Service"],"summary":"Updatea published service(without publishing).","operationId":"putPublishedService","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"allOf":[{"oneOf":[{"title":"HTTP","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}},{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["http"]},"hosts":{"type":"array","description":"The hosts for the service to accept incoming requests.","uniqueItems":true,"minItems":1,"maxItems":32,"items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"path_prefix":{"maxLength":4096,"minLength":1,"pattern":"^/","type":"string","description":"The listening path prefix of the service."},"strip_path_prefix":{"type":"boolean","default":true,"description":"Weather strip the path prefix or not when proxying the request to the upstream."},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]}}}]},{"title":"Stream","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}},{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["stream"]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}}}]}]},{"type":"object","properties":{"status":{"default":1,"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Published Service"],"summary":"Patch a published service on a gateway group.","operationId":"patchPublishedService","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Published Service"],"summary":"Delete a published service on a gateway group.","operationId":"deletePublishedService","description":"IAM Action: `gateway:DeletePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/services/{service_id}/upstreams":{"post":{"tags":["Published Service"],"summary":"Create a upstream in a published service on a gateway group.","operationId":"createPublishedServiceUpstream","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"oneOf":[{"title":"HTTPUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},{"title":"StreamUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The upstream model.","allOf":[{"oneOf":[{"title":"HTTPUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},{"title":"StreamUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"apisix_service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Published Service"],"summary":"List all upstreams in a published service on a gateway group.","operationId":"listPublishedServiceUpstreams","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"order_by","in":"query","schema":{"type":"string","default":"created_at","enum":["created_at"]}},{"name":"direction","in":"query","schema":{"type":"string","default":"asc","enum":["asc"]}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of services.","items":{"description":"The upstream model.","allOf":[{"oneOf":[{"title":"HTTPUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},{"title":"StreamUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"apisix_service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/services/{service_id}/upstreams/{upstream_id}":{"get":{"tags":["Published Service"],"summary":"Get a upstream in a published service on a gateway group.","operationId":"getPublishedServiceUpstream","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"upstream_id","description":"The unique identifier of the upstream.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The upstream model.","allOf":[{"oneOf":[{"title":"HTTPUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},{"title":"StreamUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"apisix_service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Published Service"],"summary":"Update a upstream in a published service on a gateway group.","operationId":"putPublishedServiceUpstream","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"upstream_id","description":"The unique identifier of the upstream.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"oneOf":[{"title":"HTTPUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},{"title":"StreamUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The upstream model.","allOf":[{"oneOf":[{"title":"HTTPUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},{"title":"StreamUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"apisix_service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Published Service"],"summary":"Patch a upstream in a published service on a gateway group.","operationId":"patchPublishedServiceUpstream","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"upstream_id","description":"The unique identifier of the upstream.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The upstream model.","allOf":[{"oneOf":[{"title":"HTTPUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},{"title":"StreamUpstream","description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"apisix_service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Published Service"],"summary":"Delete a upstream in a published service on a gateway group.","operationId":"deletePublishedServiceUpstream","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"upstream_id","description":"The unique identifier of the upstream.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/services/template":{"post":{"tags":["Service Template"],"summary":"Create a service template.","operationId":"createServiceTemplate","description":"IAM Action: `gateway:CreateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/*`","requestBody":{"content":{"application/json":{"schema":{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Service Template"],"summary":"Get all service templates.","operationId":"listServiceTemplates","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","last_published","name"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}},{"name":"last_publish_start_at","in":"query","required":false,"schema":{"type":"integer","minimum":0}},{"name":"last_publish_end_at","in":"query","required":false,"schema":{"type":"integer","minimum":0}},{"name":"type","in":"query","required":false,"schema":{"type":"string","enum":["http","stream"],"example":"http"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of services.","items":{"allOf":[{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/services/template/{service_template_id}":{"get":{"tags":["Service Template"],"summary":"Get a service template by ID.","operationId":"getServiceTemplate","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Service Template"],"summary":"Update a service template by ID.","operationId":"putServiceTemplate","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Service Template"],"summary":"Patch a service template by ID.","operationId":"patchServiceTemplate","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"in":"query","name":"dry-run","schema":{"type":"string","enum":["all"]},"description":"The flag that indicates whether to run the operation in dry-run mode."}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Service Template"],"summary":"Delete a service template.","operationId":"deleteServiceTemplate","description":"IAM Action: `gateway:DeleteServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/services/template/{service_template_id}/oas":{"get":{"tags":["Service Template"],"summary":"Get the OpenAPI Specification of a service template.","operationId":"getServiceTemplateOAS","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"raw_openapi":{"type":"string","description":"The OpenAPI specification of the service."},"api_count":{"type":"integer","description":"The number of APIs in the service."},"api_desc":{"type":"string","description":"The description of the OAS."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Service Template"],"summary":"Update the OpenAPI Specification of a service template.","operationId":"putServiceTemplateOAS","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"raw_openapi":{"type":"string","description":"The raw OpenAPI specification of the service."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"raw_openapi":{"type":"string","description":"The OpenAPI specification of the service."},"api_count":{"type":"integer","description":"The number of APIs in the service."},"api_desc":{"type":"string","description":"The description of the OAS."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/secret_providers":{"get":{"tags":["Secret Provider"],"summary":"List all secret providers on a gateway group.","operationId":"listSecretProviders","description":"IAM Action: `gateway:GetSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"Get all secrets.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"Array of Secret.","items":{"description":"secret with management fields","allOf":[{"allOf":[{"oneOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"secret_manger":{"type":"string","description":"secret manager type"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/secret_providers/vault/{secret_provider_id}":{"get":{"tags":["Secret Provider"],"summary":"Get a vault secret provider on a gateway group.","operationId":"getVaultSecretProvider","description":"IAM Action: `gateway:GetSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"Get a secret by ID.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"secret with management fields","allOf":[{"allOf":[{"oneOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"secret_manger":{"type":"string","description":"secret manager type"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Secret Provider"],"summary":"Delete a vault secret provider on a gateway group.","operationId":"deleteVaultSecretProvider","description":"IAM Action: `gateway:DeleteSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Secret Provider"],"summary":"Update a vault secret provider on a gateway group.","operationId":"putVaultSecretProvider","description":"IAM Action: `gateway:PutSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"allOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]}}}},"responses":{"200":{"description":"Create or update a secret by ID.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"secret with management fields","allOf":[{"allOf":[{"oneOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"secret_manger":{"type":"string","description":"secret manager type"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/secret_providers/aws/{secret_provider_id}":{"get":{"tags":["Secret Provider"],"summary":"Get a aws secret provider on a gateway group.","operationId":"getAWSSecretProvider","description":"IAM Action: `gateway:GetSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"Get a secret by ID.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"secret with management fields","allOf":[{"allOf":[{"oneOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"secret_manger":{"type":"string","description":"secret manager type"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Secret Provider"],"summary":"Delete a aws secret provider on a gateway group.","operationId":"deleteAWSSecretProvider","description":"IAM Action: `gateway:DeleteSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Secret Provider"],"summary":"Update a aws secret provider on a gateway group.","operationId":"putAWSSecretProvider","description":"IAM Action: `gateway:PutSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"allOf":[{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]}}}},"responses":{"200":{"description":"Create or update a secret by ID.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"secret with management fields","allOf":[{"allOf":[{"oneOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"secret_manger":{"type":"string","description":"secret manager type"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/secret_providers/kubernetes/{secret_provider_id}":{"get":{"tags":["Secret Provider"],"summary":"Get a kubernetes secret provider on a gateway group.","operationId":"getKubernetesSecretProvider","description":"IAM Action: `gateway:GetSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"Get a secret by ID.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"secret with management fields","allOf":[{"allOf":[{"oneOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"secret_manger":{"type":"string","description":"secret manager type"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Secret Provider"],"summary":"Delete a kubernetes secret provider on a gateway group.","operationId":"deleteKubernetesSecretProvider","description":"IAM Action: `gateway:DeleteSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Secret Provider"],"summary":"Update a kubernetes secret provider on a gateway group.","operationId":"putKubernetesSecretProvider","description":"IAM Action: `gateway:PutSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s/secret_provider/%s`","parameters":[{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]}}}},"responses":{"200":{"description":"Create or update a secret by ID.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"secret with management fields","allOf":[{"allOf":[{"oneOf":[{"description":"definition of the secret object when secret manager is vault","type":"object","required":["uri","prefix","token"],"properties":{"uri":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"prefix":{"type":"string"},"token":{"type":"string"},"namespace":{"type":"string"},"kv_version":{"type":"string","enum":["kv-v1"],"default":"kv-v1"},"authentication_method":{"type":"string","enum":["token"],"default":"token"}}},{"description":"definition of the secret object when secret manager is aws","type":"object","required":["access_key_id","secret_access_key"],"properties":{"access_key_id":{"type":"string"},"secret_access_key":{"type":"string"},"session_token":{"type":"string"},"region":{"type":"string","default":"us-east-1"},"endpoint_url":{"type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"}}},{"type":"object","properties":{"apiserver_addr":{"description":"Kubernetes API server Address.","type":"string","pattern":"^[^/]+://([\\da-zA-Z.-]+|\\[[\\da-fA-F:]+\\])(:\\d+)?"},"token":{"description":"Service account token for Kubernetes API authentication","type":"string","minLength":1},"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","minLength":1}},"oneOf":[{"required":["apiserver_addr","token"]},{"required":["apiserver_addr","token_file"]}]}]},{"type":"object","properties":{"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"secret_manger":{"type":"string","description":"secret manager type"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/export/services/template":{"post":{"tags":["Service Template"],"summary":"Generate an OpenAPI specification from service templates.","operationId":"generateOpenAPISpec","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"scope","description":"The scope of the service, which can be partial or all.","in":"query","schema":{"type":"string","enum":["partial","all"]}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["info"],"properties":{"service_ids":{"type":"array","description":"The service ID list.","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"info":{"type":"object","properties":{"title":{"type":"string"},"version":{"type":"string"},"description":{"type":"string"}},"required":["title","version"]},"servers":{"type":"array","items":{"type":"object","properties":{"url":{"type":"string"},"description":{"type":"string"}}}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"openapi":{"type":"string","description":"The OpenAPI version.","default":"3.0.1"},"info":{"type":"object","properties":{"title":{"type":"string"},"version":{"type":"string"},"description":{"type":"string"}},"required":["title","version"]},"servers":{"type":"array","items":{"type":"object","properties":{"url":{"type":"string"},"description":{"type":"string"}}}},"paths":{"type":"object","additionalProperties":{"type":"object","properties":{"get":{"type":"object","properties":{"responses":{"type":"object"}}},"put":{"type":"object","properties":{"responses":{"type":"object"}}},"post":{"type":"object","properties":{"responses":{"type":"object"}}},"delete":{"type":"object","properties":{"responses":{"type":"object"}}},"options":{"type":"object","properties":{"responses":{"type":"object"}}},"head":{"type":"object","properties":{"responses":{"type":"object"}}},"patch":{"type":"object","properties":{"responses":{"type":"object"}}}}}}},"required":["openapi","info","paths"]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/import/services/template":{"post":{"tags":["Service Template"],"summary":"Import service template based on OpenAPI Specification.","operationId":"importServiceTemplateOpenAPISpec","description":"IAM Action: `gateway:CreateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/*`","requestBody":{"content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http"],"default":"http"}}},{"type":"object","properties":{"routes":{"type":"array","minItems":1,"uniqueItems":true,"items":{"description":"The route description.","type":"object","required":["name","paths"],"properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}}}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The service with management fields.","allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"last_published":{"description":"The object timestamp.","type":"integer","minimum":0},"published_gateway_groups_count":{"type":"integer"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"routes":{"type":"array","minItems":1,"uniqueItems":true,"items":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/import/services":{"post":{"tags":["Published Service"],"summary":"Import services based on OpenAPI Specification.","operationId":"importServiceOpenAPISpec","description":"IAM Action: `gateway:CreatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/*`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http"],"default":"http"}}},{"type":"object","properties":{"routes":{"type":"array","minItems":1,"uniqueItems":true,"items":{"description":"The route description.","type":"object","required":["name","paths"],"properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}}}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"unhealthy_nodes_count":{"type":"integer"},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/openapi/convert":{"put":{"tags":["Service Template","Published Service"],"summary":"Convert OpenAPI Specification to service and route resources.","operationId":"convertOpenAPISpec","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["raw_openapi"],"properties":{"raw_openapi":{"type":"string","description":"The raw OpenAPI."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The service description.","type":"object","required":["name"],"minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"routes":{"type":"array","minItems":1,"uniqueItems":true,"items":{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]}}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/license":{"get":{"tags":["License"],"summary":"Get the API7 Enterprise license.","operationId":"getLicense","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The license object.","allOf":[{"type":"object","properties":{"customer":{"type":"string","description":"The customer name.","example":"API7"},"effective_at":{"type":"integer","format":"int64","description":"The timestamp when the license becomes effective.","example":1654012800},"expired_at":{"type":"integer","format":"int64","description":"The timestamp when the license expires.","example":1717171200},"max_dp_cores":{"type":"integer","description":"The maximum number of DP cores.","example":100},"feature_list":{"type":"array","description":"license feature list","minItems":1,"uniqueItems":true,"items":{"type":"string","enum":["API7 Gateway","API7 Portal"]}},"free_trial":{"type":"boolean","description":"whether license is free trial or not"},"is_test_env":{"type":"boolean","description":"whether license is for test env or not"},"issuance_date":{"type":"integer","format":"int64","description":"The timestamp when the license issuance."}}},{"type":"object","properties":{"runtime":{"type":"object","properties":{"status":{"type":"string","default":"normal","example":"dp_core_exceeded","enum":["normal","dp_core_exceeded","dp_core_exceeded_restricted"],"description":"The license runtime status, which can be either normal or dp_core_exceeded or dp_core_exceeded_restricted."},"dp_core_exceeded_start_at":{"type":"integer","format":"int64","description":"The start time when the number of DP cores exceeds the maximum number of DP cores of the license (buffering state)."},"dp_core_exceeded_end_at":{"type":"integer","format":"int64","description":"The end time when the number of DP cores exceeds the maximum number of DP cores of the license (buffering state). In this case, API usage will be restricted."},"max_dp_cores":{"type":"integer","format":"int64","description":"The highest number of cores during the buffering period, which is 0 in normal conditions."}}}}},{"type":"object","properties":{"status":{"type":"string","enum":["normal","expired"],"description":"The license status, which can be either normal or expired."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["License"],"summary":"Import or update the API7 Enterprise license.","operationId":"updateLicense","description":"IAM Action: `iam:UpdateLicense`, Resource: `arn:api7:iam:organization/*`","parameters":[{"in":"query","name":"dry-run","schema":{"type":"string","enum":["all"]},"description":"The flag that indicates whether to run the operation in dry-run mode."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","description":"Encoded license data.","example":"“xxxx1N-tNaTpttX-NjOdXjyg\""}},"required":["data"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The license object.","type":"object","properties":{"customer":{"type":"string","description":"The customer name.","example":"API7"},"effective_at":{"type":"integer","format":"int64","description":"The timestamp when the license becomes effective.","example":1654012800},"expired_at":{"type":"integer","format":"int64","description":"The timestamp when the license expires.","example":1717171200},"max_dp_cores":{"type":"integer","description":"The maximum number of DP cores.","example":100},"feature_list":{"type":"array","description":"license feature list","minItems":1,"uniqueItems":true,"items":{"type":"string","enum":["API7 Gateway","API7 Portal"]}},"free_trial":{"type":"boolean","description":"whether license is free trial or not"},"is_test_env":{"type":"boolean","description":"whether license is for test env or not"},"issuance_date":{"type":"integer","format":"int64","description":"The timestamp when the license issuance."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/routes":{"post":{"tags":["Route","Published Service"],"summary":"Create a route in a published service on a gateway group.","operationId":"createPublishedServiceRoute","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The route with the service ID.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","required":["service_id"],"properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Route","Published Service"],"summary":"List all routes in a published service.","operationId":"listPublishedServiceRoutes","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"query","schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of routes.","items":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/routes/{route_id}":{"get":{"tags":["Route","Published Service"],"summary":"Get a route in a published servcie on a gateway group.","operationId":"getPublishedServiceRoute","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"route_id","description":"The unique identifier of the published route.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Route","Published Service"],"summary":"Update a route in a published service on a gateway group.","operationId":"putPublishedServiceRoute","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"route_id","description":"The unique identifier of the published route.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The route with the service ID.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","required":["service_id"],"properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Route","Published Service"],"summary":"Patch a route in a published service on a gateway group.","operationId":"patchPublishedServiceRoute","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"route_id","description":"The unique identifier of the published route.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Route","Published Service"],"summary":"Delete a route in a published service on a gateway group.","operationId":"deletePublishedServiceRoute","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"route_id","description":"The unique identifier of the published route.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/routes/template":{"post":{"tags":["Service Template","Route"],"summary":"Create a route in a service template.","operationId":"createServiceTemplateRoute","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","requestBody":{"content":{"application/json":{"schema":{"description":"The route template payload.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["service_id"]}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Service Template","Route"],"summary":"Get all routes in a service template.","operationId":"listServiceTemplateRoutes","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the service template.","in":"query","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of routes.","items":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/routes/template/{route_template_id}":{"get":{"tags":["Service Template","Route"],"summary":"Get a route in all service templates.","operationId":"getServiceTemplateRoute","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"route_template_id","description":"The unique identifier of the route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Service Template"],"summary":"Update a route in service template.","operationId":"putServiceTemplateRoute","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"route_template_id","description":"The unique identifier of the route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The route with the optional service ID.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$|^$"}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Service Template","Route"],"summary":"Patch a route in service template.","operationId":"patchServiceTemplateRoute","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"route_template_id","description":"The unique identifier of the route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Service Template","Route"],"summary":"Delete a route in service template.","operationId":"deleteServiceTemplateRoute","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"route_template_id","description":"The unique identifier of the route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/stream_routes":{"post":{"tags":["Stream Route","Published Service"],"summary":"Create a stream route in a published service on a gateway group.","operationId":"createPublishedServiceStreamRoute","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The stream route with the service ID.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","required":["service_id"],"properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Stream Route","Published Service"],"summary":"List all stream routes in a published service on a gateway group.","operationId":"listPublishedServiceStreamRoutes","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the published service.","in":"query","schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of routes.","items":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/stream_routes/{stream_route_id}":{"get":{"tags":["Stream Route","Published Service"],"summary":"Get a stream stream route in a published service on a gateway group.","operationId":"getPublishedServiceStreamRoute","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"stream_route_id","description":"The unique identifier of the published stream route.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"with_publish_info","description":"Whether to include publish info in the response.","in":"query","required":false,"schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Stream Route","Published Service"],"summary":"Update a stream route in a published service on a gateway group.","operationId":"putPublishedServiceStreamRoute","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"stream_route_id","description":"The unique identifier of the published stream route.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The stream route with the service ID.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","required":["service_id"],"properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Stream Route","Published Service"],"summary":"Delete a stream route in a published service on a gateway group.","operationId":"deletePublishedServiceStreamRoute","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"stream_route_id","description":"The unique identifier of the published stream route.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/stream_routes/template":{"post":{"tags":["Stream Route","Service Template"],"summary":"Create a stream route in a service template.","operationId":"createServiceTemplateStreamRoute","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","requestBody":{"content":{"application/json":{"schema":{"description":"The stream route template payload.","allOf":[{"description":"The stream route template.","type":"object","required":["name"],"properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Stream Route","Service Template"],"summary":"List all stream routes in a service template.","operationId":"listServiceTemplateStreamRoutes","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_id","description":"The unique identifier of the service template.","in":"query","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of routes.","items":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/stream_routes/template/{stream_route_template_id}":{"get":{"tags":["Stream Route","Service Template"],"summary":"Get a stream route in a service template.","operationId":"getServiceTemplateStreamRoute","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"stream_route_template_id","description":"The unique identifier of the stream route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Stream Route","Service Template"],"summary":"Update a stream route in a service template.","operationId":"putServiceTemplateStreamRoute","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"stream_route_template_id","description":"The unique identifier of the stream route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The stream route with the optional service ID.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$|^$"}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The stream route with management fields.","allOf":[{"description":"The stream route description.","type":"object","required":["name"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Stream Route","Service Template"],"summary":"Delete a stream route in a service template.","operationId":"deleteServiceTemplateStreamRoute","description":"IAM Action: `gateway:UpdateServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"stream_route_template_id","description":"The unique identifier of the stream route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/ssls":{"post":{"deprecated":true,"tags":["SSL"],"summary":"Create a SSL certificate.","operationId":"createSSL","description":"IAM Action: `gateway:CreateSSLCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The SSL certificate description.","type":"object","oneOf":[{"required":["key","cert"]},{"required":["keys","certs"]}],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"snis":{"type":"array","description":"The SNI list for matching the SSL certificate.","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"certs":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]}},"client":{"type":"object","required":["ca"],"properties":{"ca":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"depth":{"type":"integer","minimum":0,"default":1}}},"type":{"type":"string","description":"The SSL certificate purpose, now only support server (used for communicating with the client)","enum":["server"]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]},"keys":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The SSL response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"snis":{"type":"array","description":"The SNI list for matching the SSL certificate.","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"certs":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]}},"client":{"type":"object","required":["ca"],"properties":{"ca":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"depth":{"type":"integer","minimum":0,"default":1}}},"type":{"type":"string","description":"The SSL certificate purpose, now only support server (used for communicating with the client)","enum":["server"]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}}}},"get":{"deprecated":true,"tags":["SSL"],"summary":"List all SSL certificates on a gateway group.","operationId":"listSSLs","description":"IAM Action: `gateway:GetSSLCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"type","in":"query","required":false,"schema":{"type":"string","enum":["client","server"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of SSL certificates.","items":{"description":"The SSL response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"snis":{"type":"array","description":"The SNI list for matching the SSL certificate.","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"certs":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]}},"client":{"type":"object","required":["ca"],"properties":{"ca":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"depth":{"type":"integer","minimum":0,"default":1}}},"type":{"type":"string","description":"The SSL certificate purpose, now only support server (used for communicating with the client)","enum":["server"]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/ssls/{ssl_id}":{"get":{"deprecated":true,"tags":["SSL"],"summary":"Get a SSL certificate on a gateway group.","operationId":"getSSL","description":"IAM Action: `gateway:GetSSLCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"ssl_id","description":"The unique identifier of the SSL object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The SSL response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"snis":{"type":"array","description":"The SNI list for matching the SSL certificate.","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"certs":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]}},"client":{"type":"object","required":["ca"],"properties":{"ca":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"depth":{"type":"integer","minimum":0,"default":1}}},"type":{"type":"string","description":"The SSL certificate purpose, now only support server (used for communicating with the client)","enum":["server"]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"deprecated":true,"tags":["SSL"],"summary":"Update a SSL certificate on a gateway group.","operationId":"putSSL","description":"IAM Action: `gateway:UpdateSSLCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"ssl_id","description":"The unique identifier of the SSL object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The SSL certificate description.","type":"object","oneOf":[{"required":["key","cert"]},{"required":["keys","certs"]}],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"snis":{"type":"array","description":"The SNI list for matching the SSL certificate.","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"certs":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]}},"client":{"type":"object","required":["ca"],"properties":{"ca":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"depth":{"type":"integer","minimum":0,"default":1}}},"type":{"type":"string","description":"The SSL certificate purpose, now only support server (used for communicating with the client)","enum":["server"]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]},"keys":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The SSL response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"snis":{"type":"array","description":"The SNI list for matching the SSL certificate.","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"certs":{"type":"array","minItems":1,"maxItems":1,"items":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]}},"client":{"type":"object","required":["ca"],"properties":{"ca":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"depth":{"type":"integer","minimum":0,"default":1}}},"type":{"type":"string","description":"The SSL certificate purpose, now only support server (used for communicating with the client)","enum":["server"]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"deprecated":true,"tags":["SSL"],"summary":"Delete a SSL certificate on a gateway group.","operationId":"deleteSSL","description":"IAM Action: `gateway:DeleteSSLCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"ssl_id","description":"The unique identifier of the SSL object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/certificates":{"post":{"tags":["Certificate"],"summary":"Create a certificate.","operationId":"createCertificate","description":"IAM Action: `gateway:CreateCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The certificate description.","type":"object","required":["key","cert"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"common_name":{"type":"string","description":"The common name of the certificate."},"subject_alt_names":{"type":"array","description":"The subject alternative names of the certificate.","items":{"type":"string"}},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}}}},"get":{"tags":["Certificate"],"summary":"List all certificates on a gateway group.","operationId":"listCertificates","description":"IAM Action: `gateway:GetCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"exptime","enum":["name","exptime"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"sni_id","in":"query","required":false,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"sni_name","in":"query","required":false,"schema":{"type":"string"}},{"name":"exptime","in":"query","required":false,"description":"Filter out results that expired before this time.","schema":{"type":"integer"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of certificates.","items":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"common_name":{"type":"string","description":"The common name of the certificate."},"subject_alt_names":{"type":"array","description":"The subject alternative names of the certificate.","items":{"type":"string"}},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/ca_certificates":{"post":{"tags":["CACertificate"],"summary":"Create a CA certificate.","operationId":"createCACertificate","description":"IAM Action: `gateway:CreateCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The certificate description.","type":"object","required":["cert"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}}}},"get":{"tags":["CACertificate"],"summary":"List all CA certificates on a gateway group.","operationId":"listCACertificates","description":"IAM Action: `gateway:GetCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"exptime","enum":["name","exptime"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"sni_id","in":"query","required":false,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"sni_name","in":"query","required":false,"schema":{"type":"string"}},{"name":"exptime","in":"query","required":false,"description":"Filter out results that expired before this time.","schema":{"type":"integer"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of certificates.","items":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/snis":{"post":{"tags":["SNI"],"summary":"Create a sni.","operationId":"createSNI","description":"IAM Action: `gateway:CreateSNI`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The sni description.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"domain":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"certificates":{"type":"array","minItems":1,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"mtls":{"type":"object","properties":{"enabled":{"type":"boolean","description":"Whether the MTLS is enabled.","default":false},"ca_certificates":{"type":"array","minItems":1,"description":"The CA certificates used for mTLS, only valid when mTLS is enabled","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"ssl_protocols":{"type":"array","description":"The SSL protocols.","items":{"type":"string","enum":["TLSv1.1","TLSv1.2","TLSv1.3"]},"default":["TLSv1.2","TLSv1.3"]}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"domain":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"certificates":{"type":"array","minItems":1,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"mtls":{"type":"object","properties":{"enabled":{"type":"boolean","description":"Whether the MTLS is enabled.","default":false},"ca_certificates":{"type":"array","minItems":1,"description":"The CA certificates used for mTLS, only valid when mTLS is enabled","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"ssl_protocols":{"type":"array","description":"The SSL protocols.","items":{"type":"string","enum":["TLSv1.1","TLSv1.2","TLSv1.3"]},"default":["TLSv1.2","TLSv1.3"]}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}}}},"get":{"tags":["SNI"],"summary":"List all snis on a gateway group.","operationId":"listSNIs","description":"IAM Action: `gateway:GetSNI`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"name","enum":["name"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"domain","description":"The domain of the SNI object.","in":"query","required":false,"schema":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},{"name":"mtls_enabled","description":"Whether to enable mtls.","in":"query","required":false,"schema":{"type":"array","items":{"type":"boolean"}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of snis.","items":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"domain":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"certificates":{"type":"array","minItems":1,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"mtls":{"type":"object","properties":{"enabled":{"type":"boolean","description":"Whether the MTLS is enabled.","default":false},"ca_certificates":{"type":"array","minItems":1,"description":"The CA certificates used for mTLS, only valid when mTLS is enabled","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"ssl_protocols":{"type":"array","description":"The SSL protocols.","items":{"type":"string","enum":["TLSv1.1","TLSv1.2","TLSv1.3"]},"default":["TLSv1.2","TLSv1.3"]}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/certificates/{certificate_id}":{"get":{"tags":["Certificate"],"summary":"Get a certificate on a gateway group.","operationId":"getCertificate","description":"IAM Action: `gateway:GetCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"common_name":{"type":"string","description":"The common name of the certificate."},"subject_alt_names":{"type":"array","description":"The subject alternative names of the certificate.","items":{"type":"string"}},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Certificate"],"summary":"Update a certificate on a gateway group.","operationId":"putCertificate","description":"IAM Action: `gateway:UpdateCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The certificate description.","type":"object","required":["key","cert"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"common_name":{"type":"string","description":"The common name of the certificate."},"subject_alt_names":{"type":"array","description":"The subject alternative names of the certificate.","items":{"type":"string"}},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Certificate"],"summary":"Patch a certificate on a gateway group.","operationId":"patchCertificate","description":"IAM Action: `gateway:UpdateCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"common_name":{"type":"string","description":"The common name of the certificate."},"subject_alt_names":{"type":"array","description":"The subject alternative names of the certificate.","items":{"type":"string"}},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Certificate"],"summary":"Delete a certificate on a gateway group.","operationId":"deleteCertificate","description":"IAM Action: `gateway:DeleteCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/ca_certificates/{ca_certificate_id}":{"get":{"tags":["CACertificate"],"summary":"Get a CA certificate on a gateway group.","operationId":"getCACertificate","description":"IAM Action: `gateway:GetCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"ca_certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["CACertificate"],"summary":"Update a CA certificate on a gateway group.","operationId":"putCACertificate","description":"IAM Action: `gateway:UpdateCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"ca_certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The certificate description.","type":"object","required":["cert"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["CACertificate"],"summary":"Patch a CA certificate on a gateway group.","operationId":"patchCACertificate","description":"IAM Action: `gateway:UpdateCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"ca_certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["CACertificate"],"summary":"Delete a CA certificate on a gateway group.","operationId":"deleteCACertificate","description":"IAM Action: `gateway:DeleteCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"ca_certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/snis/{sni_id}":{"get":{"tags":["SNI"],"summary":"Get a sni on a gateway group.","operationId":"getSNI","description":"IAM Action: `gateway:GetSNI`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"sni_id","description":"The unique identifier of the SNI object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"domain":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"certificates":{"type":"array","minItems":1,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"mtls":{"type":"object","properties":{"enabled":{"type":"boolean","description":"Whether the MTLS is enabled.","default":false},"ca_certificates":{"type":"array","minItems":1,"description":"The CA certificates used for mTLS, only valid when mTLS is enabled","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"ssl_protocols":{"type":"array","description":"The SSL protocols.","items":{"type":"string","enum":["TLSv1.1","TLSv1.2","TLSv1.3"]},"default":["TLSv1.2","TLSv1.3"]}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["SNI"],"summary":"Update a sni on a gateway group.","operationId":"putSNI","description":"IAM Action: `gateway:UpdateSNI`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"sni_id","description":"The unique identifier of the SNI object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The sni description.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"domain":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"certificates":{"type":"array","minItems":1,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"mtls":{"type":"object","properties":{"enabled":{"type":"boolean","description":"Whether the MTLS is enabled.","default":false},"ca_certificates":{"type":"array","minItems":1,"description":"The CA certificates used for mTLS, only valid when mTLS is enabled","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"ssl_protocols":{"type":"array","description":"The SSL protocols.","items":{"type":"string","enum":["TLSv1.1","TLSv1.2","TLSv1.3"]},"default":["TLSv1.2","TLSv1.3"]}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"domain":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"certificates":{"type":"array","minItems":1,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"mtls":{"type":"object","properties":{"enabled":{"type":"boolean","description":"Whether the MTLS is enabled.","default":false},"ca_certificates":{"type":"array","minItems":1,"description":"The CA certificates used for mTLS, only valid when mTLS is enabled","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"ssl_protocols":{"type":"array","description":"The SSL protocols.","items":{"type":"string","enum":["TLSv1.1","TLSv1.2","TLSv1.3"]},"default":["TLSv1.2","TLSv1.3"]}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["SNI"],"summary":"Patch a sni on a gateway group.","operationId":"patchSNI","description":"IAM Action: `gateway:UpdateSNI`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"sni_id","description":"The unique identifier of the SNI object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"domain":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"certificates":{"type":"array","minItems":1,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"mtls":{"type":"object","properties":{"enabled":{"type":"boolean","description":"Whether the MTLS is enabled.","default":false},"ca_certificates":{"type":"array","minItems":1,"description":"The CA certificates used for mTLS, only valid when mTLS is enabled","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"ssl_protocols":{"type":"array","description":"The SSL protocols.","items":{"type":"string","enum":["TLSv1.1","TLSv1.2","TLSv1.3"]},"default":["TLSv1.2","TLSv1.3"]}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["SNI"],"summary":"Delete a sni on a gateway group.","operationId":"deleteSNI","description":"IAM Action: `gateway:DeleteSNI`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"sni_id","description":"The unique identifier of the SNI object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/consumers":{"post":{"tags":["Consumer"],"summary":"Create a consumer on a gateway group.","operationId":"createConsumer","description":"IAM Action: `gateway:CreateConsumer`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/*`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The consumer description.","type":"object","required":["username"],"properties":{"username":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The consumer with management fields.","allOf":[{"description":"The consumer description.","type":"object","required":["username"],"properties":{"username":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Consumer"],"summary":"List all consumers on a gateway group.","operationId":"listConsumers","description":"IAM Action: `gateway:GetConsumer`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","username"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of consumers.","items":{"description":"The consumer with management fields.","allOf":[{"description":"The consumer description.","type":"object","required":["username"],"properties":{"username":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/consumers/{username}":{"get":{"tags":["Consumer"],"summary":"Get a consumer on a gateway group.","operationId":"getConsumer","description":"IAM Action: `gateway:GetConsumer`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The consumer with management fields.","allOf":[{"description":"The consumer description.","type":"object","required":["username"],"properties":{"username":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Consumer"],"summary":"Create or update a consumer on a gateway group.","operationId":"upsertConsumer","description":"IAM Action: `gateway:UpdateConsumer`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The consumer description.","type":"object","required":["username"],"properties":{"username":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The consumer with management fields.","allOf":[{"description":"The consumer description.","type":"object","required":["username"],"properties":{"username":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Consumer"],"summary":"Delete a consumer.","operationId":"deleteConsumer","description":"IAM Action: `gateway:DeleteConsumer`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Consumer"],"summary":"Update a consumer on a gateway group.","operationId":"updateConsumer","description":"IAM Action: `gateway:UpdateConsumer`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The consumer with management fields.","allOf":[{"description":"The consumer description.","type":"object","required":["username"],"properties":{"username":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/consumers/{username}/credentials":{"post":{"tags":["Consumer"],"summary":"Create a consumer credential on a gateway group.","operationId":"createConsumerCredential","description":"IAM Action: `gateway:CreateConsumerCredential`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The consumer credential description.","type":"object","required":["name","plugins"],"properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"plugins":{"type":"object","additionalProperties":false,"oneOf":[{"required":["key-auth"]},{"required":["basic-auth"]},{"required":["hmac-auth"]},{"required":["jwt-auth"]}],"properties":{"key-auth":{"type":"object"},"basic-auth":{"type":"object"},"hmac-auth":{"type":"object"},"jwt-auth":{"type":"object"}}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The consumer credential with management fields.","allOf":[{"description":"The consumer credential description.","type":"object","required":["name","plugins"],"properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"plugins":{"type":"object","additionalProperties":false,"oneOf":[{"required":["key-auth"]},{"required":["basic-auth"]},{"required":["hmac-auth"]},{"required":["jwt-auth"]}],"properties":{"key-auth":{"type":"object"},"basic-auth":{"type":"object"},"hmac-auth":{"type":"object"},"jwt-auth":{"type":"object"}}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Consumer"],"summary":"List all consumer credentials on a gateway group.","operationId":"listConsumerCredentials","description":"IAM Action: `gateway:GetConsumerCredential`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"plugin_name","description":"the plugin name of the consumer credential.","in":"query","required":false,"schema":{"description":"The object name.","type":"string","minLength":1,"maxLength":100}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","name"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of consumer credentials.","items":{"description":"The consumer credential with management fields.","allOf":[{"description":"The consumer credential description.","type":"object","required":["name","plugins"],"properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"plugins":{"type":"object","additionalProperties":false,"oneOf":[{"required":["key-auth"]},{"required":["basic-auth"]},{"required":["hmac-auth"]},{"required":["jwt-auth"]}],"properties":{"key-auth":{"type":"object"},"basic-auth":{"type":"object"},"hmac-auth":{"type":"object"},"jwt-auth":{"type":"object"}}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/consumers/{username}/credentials/{credential_id}":{"get":{"tags":["Consumer"],"summary":"Get a consumer credential on a gateway group.","operationId":"getConsumerCredential","description":"IAM Action: `gateway:GetConsumerCredential`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"credential_id","description":"The unique identifier of the consumer credential.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The consumer credential with management fields.","allOf":[{"description":"The consumer credential description.","type":"object","required":["name","plugins"],"properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"plugins":{"type":"object","additionalProperties":false,"oneOf":[{"required":["key-auth"]},{"required":["basic-auth"]},{"required":["hmac-auth"]},{"required":["jwt-auth"]}],"properties":{"key-auth":{"type":"object"},"basic-auth":{"type":"object"},"hmac-auth":{"type":"object"},"jwt-auth":{"type":"object"}}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Consumer"],"summary":"Create or update a consumer credential on a gateway group.","operationId":"upsertConsumerCredential","description":"IAM Action: `gateway:UpdateConsumerCredential`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"credential_id","description":"The unique identifier of the consumer credential.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The consumer credential description.","type":"object","required":["name","plugins"],"properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"plugins":{"type":"object","additionalProperties":false,"oneOf":[{"required":["key-auth"]},{"required":["basic-auth"]},{"required":["hmac-auth"]},{"required":["jwt-auth"]}],"properties":{"key-auth":{"type":"object"},"basic-auth":{"type":"object"},"hmac-auth":{"type":"object"},"jwt-auth":{"type":"object"}}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The consumer credential with management fields.","allOf":[{"description":"The consumer credential description.","type":"object","required":["name","plugins"],"properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"plugins":{"type":"object","additionalProperties":false,"oneOf":[{"required":["key-auth"]},{"required":["basic-auth"]},{"required":["hmac-auth"]},{"required":["jwt-auth"]}],"properties":{"key-auth":{"type":"object"},"basic-auth":{"type":"object"},"hmac-auth":{"type":"object"},"jwt-auth":{"type":"object"}}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Consumer"],"summary":"Delete a consumer credential.","operationId":"deleteConsumerCredential","description":"IAM Action: `gateway:DeleteConsumerCredential`, Resource: `arn:api7:gateway:gatewaygroup/%s/consumer/%s`","parameters":[{"name":"username","description":"The unique identifier of the consumer.","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":512,"pattern":"^[a-zA-Z0-9_\\-]+$"}},{"name":"credential_id","description":"The unique identifier of the consumer credential.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/api_products":{"post":{"tags":["API Product"],"summary":"Create an API product in Provider Portal.","operationId":"createAPIProduct-ProviderPortal","description":"IAM Action: `portal:CreateAPIProduct`, Resource: `arn:api7:portal:apiproduct/*`","requestBody":{"content":{"application/json":{"schema":{"description":"The APIProduct description.","type":"object","oneOf":[{"title":"ExternalAPIProduct","type":"object","required":["name","type","raw_openapi","server_url"],"properties":{"type":{"type":"string","enum":["external"],"default":"external"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"raw_openapi":{"type":"string","minLength":1,"description":"The content of the openapi yaml file."},"server_url":{"type":"string","minLength":1,"maxLength":4096,"description":"The server url, if its not defines on the openapi file, the user should specified it."},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"title":"GatewayAPIProduct","type":"object","required":["type","name","linked_gateway_services"],"properties":{"type":{"type":"string","enum":["gateway"],"default":"gateway"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"logo":{"type":"string","description":"The logo of the API product."},"desc":{"type":"string","description":"The description of the API product."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"auth":{"type":"object","description":"The auth configuration of the API product.","additionalProperties":false,"minProperties":1,"properties":{"key-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false},"query":{"type":"string","default":"apikey"},"header":{"type":"string","default":"apikey"}}},"basic-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false}}}}},"linked_gateway_services":{"type":"array","minItems":1,"items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"subscription_auto_approval":{"type":"boolean","default":false,"description":"Whether the subscription is auto approved or not."},"can_view_unsubscribed":{"type":"boolean","description":"Whether the developer can view the unsubscribed APIs or not.","default":true},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The APIProduct fields.","allOf":[{"oneOf":[{"title":"GatewayAPIProduct","type":"object","allOf":[{"type":"object","required":["type","name","linked_gateway_services"],"properties":{"type":{"type":"string","enum":["gateway"],"default":"gateway"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"logo":{"type":"string","description":"The logo of the API product."},"desc":{"type":"string","description":"The description of the API product."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"auth":{"type":"object","description":"The auth configuration of the API product.","additionalProperties":false,"minProperties":1,"properties":{"key-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false},"query":{"type":"string","default":"apikey"},"header":{"type":"string","default":"apikey"}}},"basic-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false}}}}},"linked_gateway_services":{"type":"array","minItems":1,"items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"subscription_auto_approval":{"type":"boolean","default":false,"description":"Whether the subscription is auto approved or not."},"can_view_unsubscribed":{"type":"boolean","description":"Whether the developer can view the unsubscribed APIs or not.","default":true},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"linked_gateway_services":{"type":"array","items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"description":"The name of the published service.","type":"string","minLength":1,"maxLength":100},"version":{"type":"string","description":"The version of the published service."},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"hosts":{"type":"array","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"openapi_title":{"type":"string","description":"The title of the openapi file."}}}}}}]},{"title":"ExternalAPIProduct","type":"object","allOf":[{"type":"object","required":["name","type","raw_openapi","server_url"],"properties":{"type":{"type":"string","enum":["external"],"default":"external"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"raw_openapi":{"type":"string","minLength":1,"description":"The content of the openapi yaml file."},"server_url":{"type":"string","minLength":1,"maxLength":4096,"description":"The server url, if its not defines on the openapi file, the user should specified it."},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"tags":{"type":"array","items":{"type":"string"}},"desc":{"type":"string"},"api_desc":{"type":"string"},"api_count":{"type":"number","format":"int64"}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"notifications":{"type":"array","items":{"allOf":[{"oneOf":[{"title":"Email","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_subject":{"type":"string"},"content":{"type":"string"}}},{"title":"Webhook","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"message":{"type":"string"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"event":{"type":"string","enum":["subscription_approval_created","subscription_approval_accepted","subscription_approval_rejected","subscription_cancelled"]},"contact_point_ids":{"type":"array","items":{"type":"string"}}}}]}}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["API Product"],"summary":"List all API products in Provider Portal.","operationId":"listAPIProducts-ProviderPortal","description":"IAM Action: `portal:GetAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"service_id","description":"The unique identifier of the service template.","in":"query","required":false,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of APIProduct.","items":{"description":"The APIProduct fields.","allOf":[{"oneOf":[{"title":"GatewayAPIProduct","type":"object","allOf":[{"type":"object","required":["type","name","linked_gateway_services"],"properties":{"type":{"type":"string","enum":["gateway"],"default":"gateway"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"logo":{"type":"string","description":"The logo of the API product."},"desc":{"type":"string","description":"The description of the API product."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"auth":{"type":"object","description":"The auth configuration of the API product.","additionalProperties":false,"minProperties":1,"properties":{"key-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false},"query":{"type":"string","default":"apikey"},"header":{"type":"string","default":"apikey"}}},"basic-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false}}}}},"linked_gateway_services":{"type":"array","minItems":1,"items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"subscription_auto_approval":{"type":"boolean","default":false,"description":"Whether the subscription is auto approved or not."},"can_view_unsubscribed":{"type":"boolean","description":"Whether the developer can view the unsubscribed APIs or not.","default":true},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"linked_gateway_services":{"type":"array","items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"description":"The name of the published service.","type":"string","minLength":1,"maxLength":100},"version":{"type":"string","description":"The version of the published service."},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"hosts":{"type":"array","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"openapi_title":{"type":"string","description":"The title of the openapi file."}}}}}}]},{"title":"ExternalAPIProduct","type":"object","allOf":[{"type":"object","required":["name","type","raw_openapi","server_url"],"properties":{"type":{"type":"string","enum":["external"],"default":"external"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"raw_openapi":{"type":"string","minLength":1,"description":"The content of the openapi yaml file."},"server_url":{"type":"string","minLength":1,"maxLength":4096,"description":"The server url, if its not defines on the openapi file, the user should specified it."},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"tags":{"type":"array","items":{"type":"string"}},"desc":{"type":"string"},"api_desc":{"type":"string"},"api_count":{"type":"number","format":"int64"}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/api_products/{api_product_id}":{"get":{"tags":["API Product"],"summary":"Get an API product in Provider Portal.","operationId":"getAPIProduct-ProviderPortal","description":"IAM Action: `portal:GetAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"api_product_id","description":"the unique identifier of the api product.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The APIProduct fields.","allOf":[{"oneOf":[{"title":"GatewayAPIProduct","type":"object","allOf":[{"type":"object","required":["type","name","linked_gateway_services"],"properties":{"type":{"type":"string","enum":["gateway"],"default":"gateway"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"logo":{"type":"string","description":"The logo of the API product."},"desc":{"type":"string","description":"The description of the API product."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"auth":{"type":"object","description":"The auth configuration of the API product.","additionalProperties":false,"minProperties":1,"properties":{"key-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false},"query":{"type":"string","default":"apikey"},"header":{"type":"string","default":"apikey"}}},"basic-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false}}}}},"linked_gateway_services":{"type":"array","minItems":1,"items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"subscription_auto_approval":{"type":"boolean","default":false,"description":"Whether the subscription is auto approved or not."},"can_view_unsubscribed":{"type":"boolean","description":"Whether the developer can view the unsubscribed APIs or not.","default":true},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"linked_gateway_services":{"type":"array","items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"description":"The name of the published service.","type":"string","minLength":1,"maxLength":100},"version":{"type":"string","description":"The version of the published service."},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"hosts":{"type":"array","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"openapi_title":{"type":"string","description":"The title of the openapi file."}}}}}}]},{"title":"ExternalAPIProduct","type":"object","allOf":[{"type":"object","required":["name","type","raw_openapi","server_url"],"properties":{"type":{"type":"string","enum":["external"],"default":"external"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"raw_openapi":{"type":"string","minLength":1,"description":"The content of the openapi yaml file."},"server_url":{"type":"string","minLength":1,"maxLength":4096,"description":"The server url, if its not defines on the openapi file, the user should specified it."},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"tags":{"type":"array","items":{"type":"string"}},"desc":{"type":"string"},"api_desc":{"type":"string"},"api_count":{"type":"number","format":"int64"}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"notifications":{"type":"array","items":{"allOf":[{"oneOf":[{"title":"Email","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_subject":{"type":"string"},"content":{"type":"string"}}},{"title":"Webhook","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"message":{"type":"string"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"event":{"type":"string","enum":["subscription_approval_created","subscription_approval_accepted","subscription_approval_rejected","subscription_cancelled"]},"contact_point_ids":{"type":"array","items":{"type":"string"}}}}]}}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["API Product"],"summary":"Update an API product in Provider Portal.","operationId":"updateAPIProduct-ProviderPortal","description":"IAM Action: `portal:UpdateAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"api_product_id","description":"the unique identifier of the api product.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The APIProduct description.","type":"object","oneOf":[{"title":"ExternalAPIProduct","type":"object","required":["name","type","raw_openapi","server_url"],"properties":{"type":{"type":"string","enum":["external"],"default":"external"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"raw_openapi":{"type":"string","minLength":1,"description":"The content of the openapi yaml file."},"server_url":{"type":"string","minLength":1,"maxLength":4096,"description":"The server url, if its not defines on the openapi file, the user should specified it."},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"title":"GatewayAPIProduct","type":"object","required":["type","name","linked_gateway_services"],"properties":{"type":{"type":"string","enum":["gateway"],"default":"gateway"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"logo":{"type":"string","description":"The logo of the API product."},"desc":{"type":"string","description":"The description of the API product."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"auth":{"type":"object","description":"The auth configuration of the API product.","additionalProperties":false,"minProperties":1,"properties":{"key-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false},"query":{"type":"string","default":"apikey"},"header":{"type":"string","default":"apikey"}}},"basic-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false}}}}},"linked_gateway_services":{"type":"array","minItems":1,"items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"subscription_auto_approval":{"type":"boolean","default":false,"description":"Whether the subscription is auto approved or not."},"can_view_unsubscribed":{"type":"boolean","description":"Whether the developer can view the unsubscribed APIs or not.","default":true},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The APIProduct fields.","allOf":[{"oneOf":[{"title":"GatewayAPIProduct","type":"object","allOf":[{"type":"object","required":["type","name","linked_gateway_services"],"properties":{"type":{"type":"string","enum":["gateway"],"default":"gateway"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"logo":{"type":"string","description":"The logo of the API product."},"desc":{"type":"string","description":"The description of the API product."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"auth":{"type":"object","description":"The auth configuration of the API product.","additionalProperties":false,"minProperties":1,"properties":{"key-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false},"query":{"type":"string","default":"apikey"},"header":{"type":"string","default":"apikey"}}},"basic-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false}}}}},"linked_gateway_services":{"type":"array","minItems":1,"items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"subscription_auto_approval":{"type":"boolean","default":false,"description":"Whether the subscription is auto approved or not."},"can_view_unsubscribed":{"type":"boolean","description":"Whether the developer can view the unsubscribed APIs or not.","default":true},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"linked_gateway_services":{"type":"array","items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"description":"The name of the published service.","type":"string","minLength":1,"maxLength":100},"version":{"type":"string","description":"The version of the published service."},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"hosts":{"type":"array","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"openapi_title":{"type":"string","description":"The title of the openapi file."}}}}}}]},{"title":"ExternalAPIProduct","type":"object","allOf":[{"type":"object","required":["name","type","raw_openapi","server_url"],"properties":{"type":{"type":"string","enum":["external"],"default":"external"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"raw_openapi":{"type":"string","minLength":1,"description":"The content of the openapi yaml file."},"server_url":{"type":"string","minLength":1,"maxLength":4096,"description":"The server url, if its not defines on the openapi file, the user should specified it."},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"tags":{"type":"array","items":{"type":"string"}},"desc":{"type":"string"},"api_desc":{"type":"string"},"api_count":{"type":"number","format":"int64"}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"notifications":{"type":"array","items":{"allOf":[{"oneOf":[{"title":"Email","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_subject":{"type":"string"},"content":{"type":"string"}}},{"title":"Webhook","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"message":{"type":"string"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"event":{"type":"string","enum":["subscription_approval_created","subscription_approval_accepted","subscription_approval_rejected","subscription_cancelled"]},"contact_point_ids":{"type":"array","items":{"type":"string"}}}}]}}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["API Product"],"summary":"Patch an API product in Provider Portal.","operationId":"patchAPIProduct-ProviderPortal","description":"IAM Action: `portal:UpdateAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"api_product_id","description":"the unique identifier of the api product.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The APIProduct fields.","allOf":[{"oneOf":[{"title":"GatewayAPIProduct","type":"object","allOf":[{"type":"object","required":["type","name","linked_gateway_services"],"properties":{"type":{"type":"string","enum":["gateway"],"default":"gateway"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"logo":{"type":"string","description":"The logo of the API product."},"desc":{"type":"string","description":"The description of the API product."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"auth":{"type":"object","description":"The auth configuration of the API product.","additionalProperties":false,"minProperties":1,"properties":{"key-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false},"query":{"type":"string","default":"apikey"},"header":{"type":"string","default":"apikey"}}},"basic-auth":{"type":"object","additionalProperties":false,"properties":{"hide_credentials":{"type":"boolean","default":false}}}}},"linked_gateway_services":{"type":"array","minItems":1,"items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"subscription_auto_approval":{"type":"boolean","default":false,"description":"Whether the subscription is auto approved or not."},"can_view_unsubscribed":{"type":"boolean","description":"Whether the developer can view the unsubscribed APIs or not.","default":true},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"linked_gateway_services":{"type":"array","items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"service_id":{"description":"The service template id of the published service.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"description":"The name of the published service.","type":"string","minLength":1,"maxLength":100},"version":{"type":"string","description":"The version of the published service."},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"hosts":{"type":"array","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"openapi_title":{"type":"string","description":"The title of the openapi file."}}}}}}]},{"title":"ExternalAPIProduct","type":"object","allOf":[{"type":"object","required":["name","type","raw_openapi","server_url"],"properties":{"type":{"type":"string","enum":["external"],"default":"external"},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"raw_openapi":{"type":"string","minLength":1,"description":"The content of the openapi yaml file."},"server_url":{"type":"string","minLength":1,"maxLength":4096,"description":"The server url, if its not defines on the openapi file, the user should specified it."},"status":{"type":"string","enum":["draft","published"],"default":"draft"},"visibility":{"type":"string","enum":["public","logged_in"],"default":"public","description":"The visibility of the API product in the API hub. Public means visible to all users, logged_in means only visible to logged in developers."}}},{"type":"object","properties":{"tags":{"type":"array","items":{"type":"string"}},"desc":{"type":"string"},"api_desc":{"type":"string"},"api_count":{"type":"number","format":"int64"}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"notifications":{"type":"array","items":{"allOf":[{"oneOf":[{"title":"Email","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_subject":{"type":"string"},"content":{"type":"string"}}},{"title":"Webhook","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"message":{"type":"string"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"event":{"type":"string","enum":["subscription_approval_created","subscription_approval_accepted","subscription_approval_rejected","subscription_cancelled"]},"contact_point_ids":{"type":"array","items":{"type":"string"}}}}]}}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["API Product"],"summary":"Delete an API product in Provider Portal.","operationId":"deleteAPIProduct-ProviderPortal","description":"IAM Action: `portal:DeleteAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"api_product_id","description":"the unique identifier of the api product.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/api_products/{api_product_id}/subscriptions":{"get":{"tags":["API Product"],"summary":"List all subscriptions in Provider Portal for an API product.","operationId":"listSubscriptions","description":"IAM Action: `portal:GetAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"api_product_id","description":"the unique identifier of the api product.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"subscribed_at","enum":["developer_name","subscribed_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of Developer user.","items":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the subscription."},"developer_id":{"type":"string"},"developer_name":{"type":"string"},"subscribed_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/api_products/{api_product_id}/subscriptions/{subscription_id}":{"delete":{"tags":["API Product"],"summary":"Cancel a subscription in Provider Portal for an API product.","operationId":"cancelSubscription","description":"IAM Action: `portal:UpdateAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"api_product_id","description":"the unique identifier of the api product.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"subscription_id","description":"the unique identifier of the subscription.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/api_products/{api_product_id}/notification_histories":{"get":{"tags":["API Product"],"summary":"List all notification histories for api_product.","description":"IAM Action: `portal:GetAPIProduct`, Resource: `arn:api7:portal:apiproduct/%s`","parameters":[{"name":"api_product_id","description":"the unique identifier of the api product.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"notification_type","description":"The type of the notification.","in":"query","schema":{"type":"string","enum":["email","webhook"]}},{"name":"event","description":"The event type of the notification.","in":"query","schema":{"type":"string","enum":["subscription_approval_created","subscription_approval_accepted","subscription_approval_rejected","subscription_cancelled"]}},{"name":"contact_point_id","description":"The contact point ids of the notification.","in":"query","schema":{"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"notified_at","enum":["notified_at"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of notification.","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"notified_at":{"description":"The object timestamp.","type":"integer","minimum":0},"notification":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"type":{"type":"string","enum":["email","webhook"]},"event":{"type":"string","enum":["subscription_approval_created","subscription_approval_accepted","subscription_approval_rejected","subscription_cancelled"]},"contact_points":{"type":"array","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string"}}}},"subject":{"type":"string"},"content":{"type":"string"},"message":{"type":"string"}}},"developer_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"developer_name":{"type":"string"},"application_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"application_name":{"type":"string"},"approval_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"subscription_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"notification_logs":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"},"contact_point_name":{"type":"string"},"resource_type":{"type":"string","enum":["alert_policy","api_product_notification"]},"resource_id":{"type":"string"},"resource_name":{"type":"string"},"status":{"type":"string"},"send_time":{"type":"integer"},"request":{"type":"string"},"response":{"type":"string"}}}},"resource_id":{"type":"string"},"resource_name":{"type":"string"}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/portal/monitor/query":{"get":{"tags":["Monitoring"],"summary":"Get portal monitro data.","operationId":"portalMonitorQuery","responses":{"200":{"description":"The Prometheus proxy response.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","description":"The Prometheus raw data.","additionalProperties":true,"example":{"status":"success","data":{"resultType":"matrix","result":[{"metric":{"label":"xxx"},"values":[[1684740675,1],[1684740690,2]]}]}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/portal/monitor/query_range":{"get":{"tags":["Monitoring"],"summary":"Get portal monitro data.","operationId":"portalMonitorQueryRange","responses":{"200":{"description":"The Prometheus proxy response.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","description":"The Prometheus raw data.","additionalProperties":true,"example":{"status":"success","data":{"resultType":"matrix","result":[{"metric":{"label":"xxx"},"values":[[1684740675,1],[1684740690,2]]}]}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/developers":{"get":{"tags":["Developer"],"summary":"List Developers.","description":"IAM Action: `portal:GetDeveloper`, Resource: `arn:api7:portal:developer/%s`","operationId":"listDeveloperUsers","parameters":[{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"last_active_at","enum":["last_active_at","created_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of Developer user.","items":{"allOf":[{"type":"object","properties":{"username":{"type":"string"},"name":{"type":"string"},"desc":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"last_active_at":{"type":"integer"},"email":{"type":"string"},"email_verified":{"type":"boolean"}}},{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"},"state":{"type":"string","description":"The state of the member.\n- Pending: The user is pending approval.\n- Active: The user had been approved.","enum":["Pending","Active"]}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/developers/invites":{"post":{"tags":["Developer"],"summary":"Invite a developer to join the portal.","description":"IAM Action: `portal:InviteDeveloper`, Resource: `arn:api7:portal:developer/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["username","password"],"properties":{"username":{"description":"The username of the user.","type":"string","minLength":1,"maxLength":128},"password":{"description":"The password of the user.","type":"string","minLength":1,"maxLength":128},"name":{"description":"The name of the user.","type":"string","minLength":1,"maxLength":128}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","properties":{"username":{"type":"string"},"name":{"type":"string"},"desc":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"last_active_at":{"type":"integer"},"email":{"type":"string"},"email_verified":{"type":"boolean"}}},{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"},"state":{"type":"string","description":"The state of the member.\n- Pending: The user is pending approval.\n- Active: The user had been approved.","enum":["Pending","Active"]}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/global_rules":{"post":{"tags":["Gateway Group","Global Rule","Plugin"],"summary":"Create a global rule on a gateway group.","operationId":"createGlobalRule","description":"IAM Action: `gateway:CreateGlobalPluginRule`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The global rule description.","type":"object","required":["plugins"],"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The global rule with management fields.","allOf":[{"description":"The global rule description.","type":"object","required":["plugins"],"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Global Rule","Gateway Group","Plugin"],"summary":"List all global rules on a gateway group.","operationId":"listGlobalRules","description":"IAM Action: `gateway:GetGlobalPluginRule`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of global rules.","items":{"description":"The global rule with management fields.","allOf":[{"description":"The global rule description.","type":"object","required":["plugins"],"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/global_rules/{global_rule_id}":{"get":{"tags":["Global Rule","Gateway Group","Plugin"],"summary":"Get a global rule on a gateway group.","operationId":"getGlobalRule","description":"IAM Action: `gateway:GetGlobalPluginRule`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"global_rule_id","description":"The unique identifier of the global rule.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The global rule with management fields.","allOf":[{"description":"The global rule description.","type":"object","required":["plugins"],"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Global Rule","Gateway Group","Plugin"],"summary":"Update a global rule on a gateway group.","operationId":"putGlobalRule","description":"IAM Action: `gateway:UpdateGlobalPluginRule`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"global_rule_id","description":"The unique identifier of the global rule.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The global rule description.","type":"object","required":["plugins"],"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The global rule with management fields.","allOf":[{"description":"The global rule description.","type":"object","required":["plugins"],"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Global Rule","Gateway Group","Plugin"],"summary":"Delete a global rule on a gateway group.","operationId":"deleteGlobalRule","description":"IAM Action: `gateway:DeleteGlobalPluginRule`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"global_rule_id","description":"The unique identifier of the global rule.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/plugin_metadata":{"get":{"tags":["Plugin Metadata","Gateway Group","Plugin"],"summary":"List all plugin metadata on a gateway group.","operationId":"listPluginMetadata","description":"IAM Action: `gateway:GetPluginMetadata`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","description":"Plugin name to metadata map.","additionalProperties":{"description":"The plugin metadata description.","type":"object"}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/plugin_metadata/{plugin_name}":{"get":{"tags":["Plugin","Plugin Metadata","Gateway Group"],"summary":"Get a plugin metadata on a gateway group.","operationId":"getPluginMetadata","description":"IAM Action: `gateway:GetPluginMetadata`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"plugin_name","in":"path","schema":{"type":"string","minLength":1,"maxLength":64},"required":true},{"name":"return_default","in":"query","schema":{"type":"boolean","description":"When set to true, the default value is returned when plugin metadata is not found.","default":false}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The plugin metadata description.","type":"object"}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Plugin Metadata","Gateway Group","Plugin"],"summary":"Update a plugin metadata on a gateway group.","operationId":"putPluginMetadata","description":"IAM Action: `gateway:UpdatePluginMetadata`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"plugin_name","in":"path","schema":{"type":"string","minLength":1,"maxLength":64},"required":true}],"requestBody":{"content":{"application/json":{"schema":{"description":"The plugin metadata description.","type":"object"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The plugin metadata description.","type":"object"}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Plugin Metadata","Gateway Group","Plugin"],"summary":"Delete a plugin metadata on a gateway group.","operationId":"deletePluginMetadata","description":"IAM Action: `gateway:DeletePluginMetadata`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"plugin_name","in":"path","schema":{"type":"string","minLength":1,"maxLength":64},"required":true}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/plugin_metadata/{plugin_name}/default":{"get":{"tags":["Plugin Metadata","Plugin"],"summary":"Get the default value of a plugin metadata.","operationId":"getPluginMetadataDefaultValue","parameters":[{"name":"plugin_name","in":"path","schema":{"type":"string","minLength":1,"maxLength":64},"required":true}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The plugin metadata description.","type":"object"}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/plugins":{"get":{"tags":["Plugin"],"summary":"Get all plugin detail","operationId":"listPluginDetail","parameters":[{"name":"subsystem","in":"query","schema":{"type":"string","default":"http","enum":["http","stream"],"example":"stream"},"description":"Filter the plugins list"}],"responses":{"200":{"description":"The plugin response.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":{"type":"object","properties":{"schema":{"type":"object"},"consumer_schema":{"type":"object"},"metadata_schema":{"type":"object"},"type":{"type":"string"},"scope":{"type":"string"},"priority":{"type":"integer"}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/plugins/list":{"get":{"tags":["Plugin"],"summary":"List all plugins.","operationId":"listPlugins","parameters":[{"name":"has_metadata","in":"query","schema":{"type":"boolean","default":false},"description":"A flag that indicates whether to filter plugins with metadata configuration."},{"name":"subsystem","in":"query","schema":{"type":"string","default":"http","enum":["http","stream"],"example":"stream"},"description":"Filter the plugins list"}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"type":"string","minLength":1,"description":"The plugin name."}}}}}}}},"/apisix/admin/plugins/{plugin_name}":{"get":{"tags":["Plugin"],"summary":"Get all properties of the specified Plugin.","operationId":"getPluginAllProperties","parameters":[{"name":"plugin_name","in":"path","schema":{"type":"string","minLength":1,"maxLength":64},"required":true},{"name":"scope","description":"The scope of the plugin.","in":"query","schema":{"type":"string","enum":["all"]}},{"name":"subsystem","in":"query","schema":{"type":"string","default":"http","enum":["http","stream"],"example":"stream"},"description":"Filter the plugins list"}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The plugin schema definition.","type":"object"}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/schema/{resource_name}":{"get":{"tags":["Schema"],"summary":"Get schema By Resource Name","operationId":"getResourceSchema","parameters":[{"name":"resource_name","in":"path","required":true,"example":"route","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object"}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/schema/plugins/{plugin_name}":{"get":{"tags":["Schema","Plugin"],"summary":"Get schema definition of single plugin.","operationId":"getPluginSchema","parameters":[{"name":"plugin_name","in":"path","schema":{"type":"string","minLength":1,"maxLength":64},"required":true},{"name":"subsystem","in":"query","schema":{"type":"string","default":"http","enum":["http","stream"],"example":"stream"},"description":"Filter the plugins list"}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The plugin schema definition.","type":"object"}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/apisix/admin/variables":{"get":{"tags":["Variables"],"summary":"Get all variables.","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The APISIX variable list.","type":"array","items":{"description":"The APISIX variable definition.","type":"object","required":["name"],"properties":{"name":{"description":"The variable name.","type":"string","minLength":1,"maxLength":128,"enum":["arg_","args","balancer_ip","balancer_port","binary_remote_addr","body_bytes_sent","bytes_received","bytes_sent","connection","connection_requests","connection_time","consumer_name","content_length","content_type","cookie_","document_root","document_uri","graphql_name","graphql_operation","graphql_root_fields","host","hostname","http2","http_","https","invalid_referer","is_args","msec","nginx_version","pid","pipe","query_string","realpath_root","remote_addr","remote_port","remote_user","request","request_body","request_body_file","request_completion","request_filename","request_id","request_length","request_method","request_time","request_uri","route_id","route_name","scheme","sent_http_","sent_trailer_","server_addr","server_name","server_port","server_protocol","service_id","service_name","ssl_alpn_protocol","ssl_cipher","ssl_ciphers","ssl_client_cert","ssl_client_escaped_cert","ssl_client_fingerprint","ssl_client_i_dn","ssl_client_i_dn_legacy","ssl_client_raw_cert","ssl_client_s_dn","ssl_client_s_dn_legacy","ssl_client_serial","ssl_client_v_end","ssl_client_v_remain","ssl_client_v_start","ssl_client_verify","ssl_curve","ssl_curves","ssl_early_data","ssl_protocol","ssl_server_name","ssl_session_id","ssl_session_reused","status","tcpinfo_rcv_space","tcpinfo_rtt","tcpinfo_rttvar","tcpinfo_snd_cwnd","time_iso8601","time_local","uri"]},"description":{"description":"The object description.","type":"string","maxLength":65536}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/instances":{"get":{"tags":["Gateway Instance"],"summary":"List all gateway instances of all gateway groups.","operationId":"listAllGatewayInstances","description":"IAM Action: `gateway:GetGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}},{"name":"order_by","in":"query","schema":{"type":"string","default":"last_heartbeat_time","enum":["created_at","last_heartbeat_time"]}},{"name":"status","in":"query","schema":{"type":"string","enum":["Healthy","OutOfSync","LostConnection","Offline"]},"description":"The value of the instance status."},{"name":"compatibility","in":"query","schema":{"type":"string","enum":["Compatible","Incompatible","PartiallyCompatible"]},"description":"The compatibility of the gateway instance version."},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of gateway instances.","items":{"type":"object","required":["id","hostname","version","ports","last_heartbeat_time","created_at","status"],"properties":{"id":{"description":"The gateway instance ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"hostname":{"type":"string","description":"The hostname of the gateway instance."},"ip":{"type":"string","description":"The IP address of the gateway instance."},"gateway_group_id":{"type":"string","minLength":1,"description":"The gateway group ID of the gateway instance."},"version":{"type":"string","description":"The version of the gateway instance."},"ports":{"type":"array","description":"The listening ports of the gateway instance.","uniqueItems":true,"minItems":1,"items":{"type":"integer"}},"last_heartbeat_time":{"description":"The last heartbeat time of the gateway instance.","type":"integer","minimum":0},"last_retrieve_config_time":{"description":"The time the gateway instance last got its configuration","type":"integer","minimum":0},"to_be_deleted_at":{"nullable":true,"description":"The duration to delete offline instances from the instance list.","type":"integer","minimum":0},"created_at":{"description":"The first heartbeat time of the gateway instance.","type":"integer","minimum":0},"dataplane_certificate_expire_time":{"nullable":true,"description":"The expiration time of the certificate used for mTLS connection between the data plane and the control plane.","type":"integer","minimum":0},"status":{"type":"string","description":"Status enumeration:\n- Healthy: indicates the gateway instance is healthy. Note Healthy means\n  the heartbeat probes sent from instance are received periodically and the configuration delivery is also normal (configuration revision synced).\n- OutOfSync: indicates the gateway instance sends heartbeat probes\n  periodically but the configuration cannot be delivered to the instance (configuration revision out of synced).\n- LostConnection: indicates the gateway instance loses heartbeat in short time ( 2 minutes < t < 2 hours )\n- Offline: indicates the gateway instance loses heartbeat in long time ( 2 hours < t < 7 days )\n\nPlease note that gateway instances that have been offline for more than 7 days will be removed from the system and will not be included in this API.","enum":["Healthy","OutOfSync","LostConnection","Offline"]},"cores":{"type":"integer","description":"The number of DP cores."},"compatibility":{"type":"string","description":"Compatibility enumeration:\n- Compatible: The gateway instance is fully compatible with the control plane, and all functionalities operate as expected.\n- Incompatible: The gateway instance is not compatible with the control plane, and critical functionalities may not work.\n- PartiallyCompatible: The gateway instance has limited compatibility with the control plane, and some functionalities may not work as expected.","enum":["Compatible","Incompatible","PartiallyCompatible"]}}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/instances":{"get":{"tags":["Gateway Instance","Gateway Group"],"summary":"List all gateway instances on a gateway group.","operationId":"listGatewayInstances","description":"IAM Action: `gateway:GetGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"order_by","in":"query","schema":{"type":"string","default":"last_heartbeat_time","enum":["created_at","last_heartbeat_time"]}},{"name":"status","in":"query","schema":{"type":"string","enum":["Healthy","OutOfSync","LostConnection","Offline"]},"description":"The value of the instance status."},{"name":"compatibility","in":"query","schema":{"type":"string","enum":["Compatible","Incompatible","PartiallyCompatible"]},"description":"The compatibility of the gateway instance version."},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of gateway instances.","items":{"type":"object","required":["id","hostname","version","ports","last_heartbeat_time","created_at","status"],"properties":{"id":{"description":"The gateway instance ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"hostname":{"type":"string","description":"The hostname of the gateway instance."},"ip":{"type":"string","description":"The IP address of the gateway instance."},"gateway_group_id":{"type":"string","minLength":1,"description":"The gateway group ID of the gateway instance."},"version":{"type":"string","description":"The version of the gateway instance."},"ports":{"type":"array","description":"The listening ports of the gateway instance.","uniqueItems":true,"minItems":1,"items":{"type":"integer"}},"last_heartbeat_time":{"description":"The last heartbeat time of the gateway instance.","type":"integer","minimum":0},"last_retrieve_config_time":{"description":"The time the gateway instance last got its configuration","type":"integer","minimum":0},"to_be_deleted_at":{"nullable":true,"description":"The duration to delete offline instances from the instance list.","type":"integer","minimum":0},"created_at":{"description":"The first heartbeat time of the gateway instance.","type":"integer","minimum":0},"dataplane_certificate_expire_time":{"nullable":true,"description":"The expiration time of the certificate used for mTLS connection between the data plane and the control plane.","type":"integer","minimum":0},"status":{"type":"string","description":"Status enumeration:\n- Healthy: indicates the gateway instance is healthy. Note Healthy means\n  the heartbeat probes sent from instance are received periodically and the configuration delivery is also normal (configuration revision synced).\n- OutOfSync: indicates the gateway instance sends heartbeat probes\n  periodically but the configuration cannot be delivered to the instance (configuration revision out of synced).\n- LostConnection: indicates the gateway instance loses heartbeat in short time ( 2 minutes < t < 2 hours )\n- Offline: indicates the gateway instance loses heartbeat in long time ( 2 hours < t < 7 days )\n\nPlease note that gateway instances that have been offline for more than 7 days will be removed from the system and will not be included in this API.","enum":["Healthy","OutOfSync","LostConnection","Offline"]},"cores":{"type":"integer","description":"The number of DP cores."},"compatibility":{"type":"string","description":"Compatibility enumeration:\n- Compatible: The gateway instance is fully compatible with the control plane, and all functionalities operate as expected.\n- Incompatible: The gateway instance is not compatible with the control plane, and critical functionalities may not work.\n- PartiallyCompatible: The gateway instance has limited compatibility with the control plane, and some functionalities may not work as expected.","enum":["Compatible","Incompatible","PartiallyCompatible"]}}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/instances/count/{field}":{"get":{"tags":["Gateway Instance","Gateway Group"],"summary":"Calculate the number of instances in different states of a gateway group.","operationId":"countGatewayInstancesStatus","description":"IAM Action: `gateway:GetGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","description":"It's optional when client authenticate with gateway group admin key.","in":"query","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"field","in":"path","required":true,"schema":{"type":"string","enum":["status"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"array","description":"An array of gateway instance count status.","items":{"type":"object","properties":{"key":{"type":"string"},"count":{"type":"integer"}}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/instances/cores":{"get":{"tags":["Gateway Instance"],"summary":"List gateway instances cores of all gateway groups.","operationId":"listAllGatewayInstancesCores","description":"IAM Action: `gateway:GetGatewayInstanceCore`, Resource: `arn:api7:gateway:gatewaygroup/*`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"current_dp_cores":{"type":"integer","description":"The current DP cores.","example":1}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/instances/cores_usages/export":{"get":{"tags":["Gateway Instance","Gateway Group"],"summary":"Export the gateway instance core usage.","operationId":"exportGatewayInstancesCoresUsage","description":"IAM Action: `gateway:GetGatewayInstanceCore`, Resource: `arn:api7:gateway:gatewaygroup/*`","parameters":[{"name":"begin_at","in":"query","required":true,"description":"The start time of gateway instance core usage.","schema":{"type":"integer","format":"int64"}},{"name":"end_at","in":"query","required":true,"description":"The end time of gateway instance core usage.","schema":{"type":"integer","format":"int64"}}],"responses":{"200":{"description":"","content":{"text/csv":{"schema":{"type":"object","properties":{"time":{"type":"integer","format":"int64"},"max_dp_cores":{"type":"integer","format":"int64"}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}}}}},"/api/users":{"get":{"tags":["User"],"summary":"List all users.","operationId":"listUsers","description":"IAM Action: `iam:GetUser`, Resource: `arn:api7:iam:user/%s`","parameters":[{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"roles","in":"query","schema":{"type":"array","items":{"type":"string"},"minimum":1}},{"name":"login_option_name","in":"query","schema":{"type":"array","items":{"type":"string"},"minimum":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of users.","items":{"description":"The details for a user. It's user-specific information in an organization.","allOf":[{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"username":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"email_verified":{"type":"boolean"}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"state":{"type":"string","description":"The state of the member.\n- Pending: The user is pending approval.\n- Active: The user had accepted the invitation."},"provider":{"type":"string","description":"tag where user from","enum":["builtin","sso","scim"]},"roles":{"description":"A series of roles to be assigned to a user.","type":"array","minItems":1,"maxItems":32,"items":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The unique identifier of the role.","type":"string"},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}}}}},"boundaries":{"description":"A series of boundaries to be assigned to the user.","type":"array","items":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/users/{user_id}":{"get":{"tags":["User"],"summary":"Get a user.","operationId":"getUser","description":"IAM Action: `iam:GetUser`, Resource: `arn:api7:iam:user/%s`","parameters":[{"name":"user_id","in":"path","description":"The user ID.","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The details for a user. It's user-specific information in an organization.","allOf":[{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"username":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"email_verified":{"type":"boolean"}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"state":{"type":"string","description":"The state of the member.\n- Pending: The user is pending approval.\n- Active: The user had accepted the invitation."},"provider":{"type":"string","description":"tag where user from","enum":["builtin","sso","scim"]},"roles":{"description":"A series of roles to be assigned to a user.","type":"array","minItems":1,"maxItems":32,"items":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The unique identifier of the role.","type":"string"},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}}}}},"boundaries":{"description":"A series of boundaries to be assigned to the user.","type":"array","items":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["User"],"summary":"Update basic attributes of a user.","operationId":"updateUser","description":"IAM Action: `iam:UpdateUser`, Resource: `arn:api7:iam:user/%s`","parameters":[{"name":"user_id","in":"path","description":"The user ID.","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["User"],"summary":"Delete a user.","operationId":"deleteUser","description":"IAM Action: `iam:DeleteUser`, Resource: `arn:api7:iam:user/%s`","parameters":[{"name":"user_id","in":"path","description":"The user ID.","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/users/{user_id}/boundaries":{"put":{"tags":["User"],"summary":"Update the user's permission boundaries.","operationId":"updateUserBoundaries","description":"IAM Action: `iam:UpdateUserBoundary`, Resource: `arn:api7:iam:user/%s`","parameters":[{"name":"user_id","in":"path","description":"The user ID.","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"string"}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/users/{user_id}/password_reset":{"put":{"tags":["User"],"summary":"Reset the password to specific value.","operationId":"passwordReset","description":"IAM Action: `iam:ResetPassword`, Resource: `arn:api7:iam:user/%s`","parameters":[{"name":"user_id","in":"path","description":"The user ID.","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"description":"The request to reset the password.","type":"object","required":["password"],"properties":{"password":{"description":"The password of the user.","type":"string","minLength":1,"maxLength":128}}}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}}}}},"/api/me":{"get":{"tags":["User"],"summary":"Get my user detail.","operationId":"getUserMe","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The details for a user. It's user-specific information in an organization.","allOf":[{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"username":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"email_verified":{"type":"boolean"}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"state":{"type":"string","description":"The state of the member.\n- Pending: The user is pending approval.\n- Active: The user had accepted the invitation."},"provider":{"type":"string","description":"tag where user from","enum":["builtin","sso","scim"]},"roles":{"description":"A series of roles to be assigned to a user.","type":"array","minItems":1,"maxItems":32,"items":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The unique identifier of the role.","type":"string"},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}}}}},"boundaries":{"description":"A series of boundaries to be assigned to the user.","type":"array","items":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["User"],"summary":"Update my user profile.","operationId":"putUserMe","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","minLength":1,"maxLength":200}}}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/me/email":{"put":{"tags":["User"],"summary":"Update the user email.","operationId":"putUserEmail","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["email"],"properties":{"email":{"type":"string","format":"email","minLength":1,"maxLength":128}}}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["User"],"summary":"Delete the user email.","operationId":"deleteUserEmail","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/email_verified":{"get":{"tags":["Email"],"summary":"Check if email is verified","operationId":"checkEmailVerified","parameters":[{"name":"email","in":"query","required":true,"schema":{"type":"string","format":"email","minLength":1,"maxLength":255}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"verified":{"type":"boolean"}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/verify_email":{"get":{"tags":["Email"],"summary":"get email verification","operationId":"getEmailVerification","parameters":[{"name":"token","description":"the token of the request.","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":1024}}],"responses":{"302":{"description":"Redirect to IDP.","content":{}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/invites":{"post":{"tags":["User"],"summary":"Invite a user.","operationId":"inviteUser","description":"IAM Action: `iam:InviteUser`, Resource: `arn:api7:iam:user/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["username","password"],"properties":{"username":{"description":"The username of the user.","type":"string","minLength":1,"maxLength":128},"password":{"description":"The password of the user.","type":"string","minLength":1,"maxLength":128},"boundaries":{"description":"The permission boundaries of the user.","type":"array","items":{"type":"string"}},"name":{"description":"The name of the user.","type":"string","minLength":1,"maxLength":128}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The details for a user. It's user-specific information in an organization.","allOf":[{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"username":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"email_verified":{"type":"boolean"}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"state":{"type":"string","description":"The state of the member.\n- Pending: The user is pending approval.\n- Active: The user had accepted the invitation."},"provider":{"type":"string","description":"tag where user from","enum":["builtin","sso","scim"]},"roles":{"description":"A series of roles to be assigned to a user.","type":"array","minItems":1,"maxItems":32,"items":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The unique identifier of the role.","type":"string"},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}}}}},"boundaries":{"description":"A series of boundaries to be assigned to the user.","type":"array","items":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]},{"type":"object","properties":{"invitation_link":{"type":"string","description":"The invitation link of the user."}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/password":{"put":{"tags":["User"],"summary":"Update the user password.","operationId":"updateUserPassword","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["new_password"],"properties":{"old_password":{"type":"string","minLength":1,"maxLength":128},"new_password":{"type":"string","minLength":1,"maxLength":128}}}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}}}}},"/api/login":{"post":{"tags":["User"],"summary":"Log in to API7 Enterprise using the username and password.","operationId":"userLogin","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["username","password"],"properties":{"username":{"description":"The username of the user.","type":"string","minLength":1,"maxLength":128},"password":{"description":"The password of the user.","type":"string","minLength":1,"maxLength":128}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/logout":{"post":{"tags":["User"],"summary":"Log out from API7 Enterprise using the username and password.","operationId":"userLogout","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/users/{user_id}/assigned_roles":{"put":{"tags":["User","Role"],"summary":"Update assigned roles for a user.","operationId":"addAssignedRole","description":"IAM Action: `iam:UpdateUserRole`, Resource: `arn:api7:iam:user/%s`","parameters":[{"name":"user_id","in":"path","description":"The user ID.","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"roles":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}},"required":["roles"]}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/roles":{"get":{"tags":["Role"],"summary":"List all roles.","operationId":"listRoles","description":"IAM Action: `iam:GetRole`, Resource: `arn:api7:iam:role/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of roles.","items":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["Role"],"summary":"Create a role.","operationId":"createRole","description":"IAM Action: `iam:CreateRole`, Resource: `arn:api7:iam:role/*`","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"The role name.","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policies":{"type":"array","description":"The polices attached to the role.","minItems":1,"uniqueItems":true,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/roles/{role_id}":{"get":{"tags":["Role"],"summary":"Get a role.","operationId":"getRole","description":"IAM Action: `iam:GetRole`, Resource: `arn:api7:iam:role/%s`","parameters":[{"name":"role_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Role"],"summary":"Update a role.","operationId":"putRole","description":"IAM Action: `iam:UpdateRole`, Resource: `arn:api7:iam:role/%s`","parameters":[{"name":"role_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"The role name.","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policies":{"type":"array","description":"The polices attached to the role.","minItems":1,"uniqueItems":true,"items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The specification of the role of the user.","type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The role name."},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"type":{"type":"string","enum":["built_in","custom"]},"policies":{"type":"array","description":"The policies of the role.","items":{"type":"string"}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Role"],"summary":"Delete a role.","operationId":"deleteRole","description":"IAM Action: `iam:DeleteRole`, Resource: `arn:api7:iam:role/%s`","parameters":[{"name":"role_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/roles/{role_id}/permission_policies":{"get":{"tags":["Role","Permission Policy"],"summary":"List all permission policies attached to a role.","operationId":"listRolePermissionPolicies","description":"IAM Action: `iam:GetPermissionPolicy`, Resource: `arn:api7:iam:permissionpolicy/%s`","parameters":[{"name":"role_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of permission policies.","items":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/roles/{role_id}/attach_permission_policies":{"post":{"tags":["Role","Permission Policy"],"summary":"Attach permission policies to a role.","operationId":"attachPermissionPolicies","description":"IAM Action: `iam:UpdateRole`, Resource: `arn:api7:iam:role/%s`","parameters":[{"name":"role_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"string"}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/roles/{role_id}/detach_permission_policies":{"post":{"tags":["Role","Permission Policy"],"summary":"Detach permission policies of a role.","operationId":"detachPermissionPolicies","description":"IAM Action: `iam:UpdateRole`, Resource: `arn:api7:iam:role/%s`","parameters":[{"name":"role_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"string"}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/permission_policies":{"post":{"tags":["Permission Policy"],"summary":"Create a permission policy.","operationId":"createPermissionPolicy","description":"IAM Action: `iam:CreatePermissionPolicy`, Resource: `arn:api7:iam:permissionpolicy/*`","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Permission Policy"],"summary":"List all permission policies.","operationId":"listPermissionPolicies","description":"IAM Action: `iam:GetPermissionPolicy`, Resource: `arn:api7:iam:permissionpolicy/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of permission policies.","items":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/permission_policies/{permission_policy_id}":{"get":{"tags":["Permission Policy"],"summary":"Get a permission policy.","operationId":"getPermissionPolicy","description":"IAM Action: `iam:GetPermissionPolicy`, Resource: `arn:api7:iam:permissionpolicy/%s`","parameters":[{"name":"permission_policy_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Permission Policy"],"summary":"Update a permission policy.","operationId":"putPermissionPolicy","description":"IAM Action: `iam:UpdatePermissionPolicy`, Resource: `arn:api7:iam:permissionpolicy/%s`","parameters":[{"name":"permission_policy_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","properties":{"name":{"description":"The policy name.","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The permission policy type."},"desc":{"description":"The description of the policy.","type":"string","maxLength":65536},"labels":{"description":"The labels of the policy.","type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"policy_document":{"type":"object","properties":{"statement":{"type":"array","description":"The statements of the policy.","minItems":1,"items":{"type":"object","properties":{"effect":{"type":"string","enum":["allow","deny"]},"resources":{"type":"array","description":"The resources for requests.","items":{"type":"string","example":"gateway:GatewayGroup"},"minItems":1,"example":["arn:api7:gateway:servicetemplate/<.*>"]},"actions":{"type":"array","description":"The actions for requests.","items":{"anyOf":[{"type":"string"}]},"example":["gateway:GetServiceTemplate"],"minItems":1},"conditions":{"type":"object","description":"Rules for matching requests. The key is the condition name, the value is the condition expression \nwhich specifies the function name and parameter structure of condition.\n","anyOf":[{"title":"ConditionForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForService","type":"object","properties":{"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"service_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForRole","type":"object","properties":{"role_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForUser","type":"object","properties":{"user_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"permission_boundaries":{"type":"object","description":"Match two string arrays, when the elements are exactly the same (regardless of the order of the elements), the match is successful.\nWhen granting iam:InviteUser privilege to a user, this Condition can be used to constrain the boundaries that need to be set for the invited user.\nWhen granting iam:UpdateUserBoundary privilege to a user, this Condition can be used to constrain the boundaries that that need to be set for the updated user.\n","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"AllOfStrings","enum":["AllOfStrings"]},"options":{"type":"array","items":{"type":"string"}}},"example":{"type":"AllOfStrings","options":["permission_policy_a","permission_policy_b"]}}}},{"title":"ConditionForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"consumer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}},"secret_provider_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForDeveloper","type":"object","properties":{"developer_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForCertificate","type":"object","properties":{"certificate_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}},{"title":"ConditionForSNI","type":"object","properties":{"sni_label":{"type":"object","description":"Condition for gatewayGroup or service","properties":{"type":{"type":"string","description":"The condition name is also known as the function name.","example":"MatchLabel","enum":["MatchLabel"]},"options":{"type":"object","properties":{"key":{"type":"string"},"operator":{"type":"string","enum":["exact_match","contains_string","present"]},"value":{"type":"string"}},"example":{"key":"env","operation":"exact_match","value":"prod"}}}}}}]}},"required":["effect","resources","actions"],"additionalProperties":false}}},"required":["statement"],"additionalProperties":false}},"required":["name","policy_document"]},{"type":"object","properties":{"id":{"description":"The policy ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Permission Policy"],"summary":"Delete a permission policy.","operationId":"deletePermissionPolicy","description":"IAM Action: `iam:DeletePermissionPolicy`, Resource: `arn:api7:iam:permissionpolicy/%s`","parameters":[{"name":"permission_policy_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/permission_policies/{permission_policy_id}/references":{"get":{"tags":["Permission Policy"],"summary":"List which Roles or Users directly reference the Permission Policy.","operationId":"listPermissionPolicyReferences","description":"IAM Action: `iam:GetPermissionPolicy`, Resource: `arn:api7:iam:permissionpolicy/%s`","parameters":[{"name":"permission_policy_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","items":{"type":"object","description":"Indicates which Role or User references the PermissionPolicy.","properties":{"type":{"type":"string","description":"Referenced by Role or User.","enum":["role","user"]},"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/allow_access":{"post":{"tags":["Role","User"],"summary":"Check if a user has certain permissions on certain resources.","operationId":"checkAllowAccess","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"object","properties":{"resource":{"type":"string"},"action":{"type":"string"},"context":{"type":"object","anyOf":[{"title":"ContextForGatewayGroup","type":"object","properties":{"gateway_group_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForService","type":"object","properties":{"service_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForPublishedService","type":"object","properties":{"gateway_group_label":{"type":"object","additionalProperties":{"type":"string"}},"service_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForRole","type":"object","properties":{"role_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForPermissionPolicy","type":"object","properties":{"permission_policy_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForUser","type":"object","properties":{"user_label":{"type":"object","additionalProperties":{"type":"string"}},"permission_boundaries":{"type":"array","items":{"type":"string"}}}},{"title":"ContextForConsumer","type":"object","properties":{"gateway_group_label":{"type":"object","additionalProperties":{"type":"string"}},"consumer_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForSecret","type":"object","properties":{"gateway_group_label":{"type":"object","additionalProperties":{"type":"string"}},"secret_provider_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForContactPoint","type":"object","properties":{"contact_point_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForAlertPolicy","type":"object","properties":{"alert_policy_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForDeveloper","type":"object","properties":{"developer_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForAPIProduct","type":"object","properties":{"api_product_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForCaCertificate","type":"object","properties":{"ca_certificate_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForCertificate","type":"object","properties":{"certificate_label":{"type":"object","additionalProperties":{"type":"string"}}}},{"title":"ContextForSNI","type":"object","properties":{"sni_label":{"type":"object","additionalProperties":{"type":"string"}}}}]}},"required":["resource","action"]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","additionalProperties":{"type":"boolean"}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/control_plane/prometheus/{prometheus_path}":{"parameters":[{"name":"prometheus_path","in":"path","required":true,"description":"The path to the Prometheus API.","schema":{"type":"string","example":"api/v1/query_range?query=xxx&start=1684722195&end=1684723995&step=15"}}],"get":{"tags":["Monitoring"],"summary":"Get data from Prometheus.","operationId":"getPrometheusData","responses":{"200":{"description":"The Prometheus proxy response.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","description":"The Prometheus raw data.","additionalProperties":true,"example":{"status":"success","data":{"resultType":"matrix","result":[{"metric":{"label":"xxx"},"values":[[1684740675,1],[1684740690,2]]}]}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["Monitoring"],"summary":"Get data from Prometheus (with post).","operationId":"getPrometheusDataWithPost","requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"The Prometheus proxy response.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","description":"The Prometheus raw data.","additionalProperties":true,"example":{"status":"success","data":{"resultType":"matrix","result":[{"metric":{"label":"xxx"},"values":[[1684740675,1],[1684740690,2]]}]}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/dataplane/heartbeat":{"post":{"tags":["Gateway Instance"],"summary":"Send a heartbeat to all gateway instances.","operationId":"gatewayInstanceHeartbeat","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["instance_id","hostname","version","ports"],"properties":{"instance_id":{"description":"The gateway instance ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"run_id":{"type":"string","description":"The run ID of the gateway instance."},"hostname":{"type":"string","description":"The hostname of the gateway instance."},"ip":{"type":"string","description":"The IP address of the gateway instance."},"version":{"type":"string","description":"The version of the gateway instance."},"ports":{"type":"array","description":"The listening ports of the gateway instance.","uniqueItems":true,"minItems":1,"items":{"type":"integer"}},"cores":{"type":"integer","description":"The number of DP cores."},"control_plane_revision":{"type":"string","description":"The configuration version currently used by the data plane."},"conf_server_revision":{"type":"string","description":"Replace with control_plane_revision.","deprecated":true}}}}}},"responses":{"403":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/dataplane/metrics":{"post":{"tags":["Gateway Instance"],"summary":"Generate metrics based on all gateway instances.","operationId":"gatewayInstanceMetrics","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["instance_id","metrics"],"properties":{"instance_id":{"description":"The gateway instance ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"truncated":{"type":"boolean","description":"Whether to truncate the reported metrics due to exceeding the single report size limit."},"metrics":{"type":"string","description":"Format the text in Prometheus metric format."}}}}}},"responses":{"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/dataplane/healthcheck":{"post":{"tags":["Gateway Instance"],"summary":"Report the health check results of all gateway instances based on its health check configuration.","operationId":"reportGatewayInstanceHealthCheckStatus","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["instance_id"],"properties":{"instance_id":{"description":"The gateway instance ID.","type":"string","minLength":1,"example":"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"},"data":{"type":"array","description":"Item is a node healthcheck data.","items":{"type":"object","description":"Node healthcheck data.","required":["upstream_id"],"properties":{"upstream_id":{"type":"string","description":"Upstream Id","minLength":1,"example":"uuu-ppp-sss-ttt-rrr-eee-aaa-mmm"},"nodes":{"type":"array","description":"Nodes","items":{"type":"object","description":"Node's healthcheck status data.","required":["host","port","status"],"properties":{"host":{"type":"string","example":"httpbin.org"},"port":{"type":"integer","example":80},"status":{"type":"string","description":"node's health status","enum":["healthy","unhealthy","unknown"],"example":"healthy"}}}}}}}}}}}},"responses":{"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/dataplane/service_registry_healthcheck":{"post":{"tags":["Gateway Instance"],"summary":"Report the service registry health check results from gateway instance.","operationId":"reportServiceRegistryHealthCheckStatus","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["instance_id"],"properties":{"instance_id":{"description":"The gateway instance ID.","type":"string","minLength":1,"example":"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"},"data":{"type":"array","description":"Item is a service registry healthcheck data.","items":{"type":"object","description":"Service registry healthcheck data.","required":["service_registry_id"],"properties":{"service_registry_id":{"type":"string","description":"Service Registry ID","minLength":1,"example":"uuu-ppp-sss-ttt-rrr-eee-aaa-mmm"},"status":{"type":"integer","description":"Status","enum":[0,1]},"hostname":{"type":"string","description":"Hostname of the DP instance.","minLength":1,"example":"apisix-hostname"},"time":{"type":"integer","minimum":1720602869,"description":"Time when status was reported."}}}}}}}}},"responses":{"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/dataplane/consumer_query":{"get":{"tags":["Dataplane Consumer"],"summary":"Get the consumer based on the plugin name and key value.","operationId":"consumerQuery","parameters":[{"name":"username","in":"query","description":"The consumer username.","schema":{"type":"string"}},{"name":"plugin_name","in":"query","description":"The plugin name.","schema":{"type":"string","enum":["key-auth","basic-auth","jwt-auth","hmac-auth"]}},{"name":"key_value","in":"query","description":"The key value.","schema":{"type":"string"}}],"responses":{"default":{"description":"The response for getting the consumer.","content":{"application/json":{"schema":{"type":"object","properties":{"username":{"type":"string","description":"The consumer username."},"consumer_name":{"type":"string","description":"The consumer username."},"auth_conf":{"type":"object","description":"The consumer auth conf."},"labels":{"type":"object","description":"The consumer labels."},"plugins":{"type":"object","description":"The consumer plugins."},"credential_id":{"type":"string","description":"The consumer credential id."}}}}}}}}},"/api/dataplane/developer_query":{"get":{"tags":["Dataplane Developer"],"summary":"Get the developer based on the plugin name and key value.","operationId":"developerQuery","parameters":[{"name":"plugin_name","in":"query","description":"The plugin name.","schema":{"type":"string","enum":["key-auth","basic-auth"]}},{"name":"key_value","in":"query","description":"The key value.","schema":{"type":"string"}},{"name":"service_id","in":"query","description":"The matched service id.","schema":{"type":"string"}}],"responses":{"default":{"description":"The response for getting the consumer.","content":{"application/json":{"schema":{"type":"object","properties":{"username":{"type":"string","description":"The consumer username."},"consumer_name":{"type":"string","description":"The consumer username."},"auth_conf":{"type":"object","description":"The consumer auth conf."},"labels":{"type":"object","description":"The consumer labels."},"plugins":{"type":"object","description":"The consumer plugins."},"credential_id":{"type":"string","description":"The consumer credential id."}}}}}}}}},"/api/alert/policies":{"get":{"tags":["Alert"],"summary":"List all alert policies.","operationId":"listAlertPolicies","description":"IAM Action: `gateway:GetAlertPolicy`, Resource: `arn:api7:gateway:alert/%s`","parameters":[{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","name","severity"]}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"status","in":"query","required":false,"schema":{"type":"array","items":{"type":"string","enum":["enabled","disabled"]}}},{"name":"severity","in":"query","required":false,"schema":{"type":"array","items":{"type":"string","enum":["high","medium","low"]}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of alert policies","items":{"description":"The definition of an alert policy.","type":"object","allOf":[{"type":"object","required":["name","trigger_logical_operator","trigger_conditions"],"properties":{"name":{"description":"The alert policy name.","type":"string","minLength":1,"maxLength":100},"desc":{"description":"The alert policy description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"enable":{"type":"boolean","description":"Whether the alert policy is enabled.","default":true},"check_interval":{"type":"integer","description":"The check interval for the alert policy. The unit is second.","minimum":1,"maximum":86400},"severity":{"type":"string","description":"The alert severity level.","default":"medium","enum":["high","medium","low"]},"trigger_logical_operator":{"type":"string","description":"The logical relationship between multiple triggers.","enum":["All","Any"],"default":"All"},"trigger_conditions":{"type":"array","description":"The alert trigger conditions.","minItems":1,"items":{"type":"object","oneOf":[{"title":"Status Code","properties":{"event":{"type":"string","enum":["number_of_status_code","ratio_of_status_code"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"event_config":{"type":"object","properties":{"duration":{"type":"integer","description":"The duration time.","minimum":1},"unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]},"http_status_code":{"type":"string","description":"The HTTP status code.","pattern":"[2-5]\\d{2}|[2-5]xx"}},"required":["http_status_code","duration","unit"]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"}},"required":["event","event_config","operator","value","scope"]},{"title":"Certificate Expiry","properties":{"event":{"type":"string","enum":["ssl_certificate_will_expire_in","gateway_certificate_will_expire_in"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Gateway Instance Offline","properties":{"event":{"type":"string","enum":["gateway_instance_offline"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["equal","larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Dataplane Cores Exceeded","properties":{"event":{"type":"string","enum":["dp_core_exceeded"],"description":"The event of trigger."}}},{"title":"Numbers of Healthy Gateway Instances","properties":{"event":{"type":"string","enum":["number_of_healthy_gateway_instances"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"],"default":"less_equal"},"value":{"type":"integer","format":"int64"}},"required":["event","scope","operator","value"]}]}},"notifications":{"type":"array","description":"The alert notifications.","items":{"type":"object","required":["type"],"oneOf":[{"type":"object","required":["type","subject","content"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["email"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"subject":{"type":"string","description":"The email subject.","minLength":1},"content":{"type":"string","description":"The email content.","minLength":1,"format":"go_template"}}},{"type":"object","required":["type","alert_message"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["webhook"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"alert_message":{"type":"string","description":"The alert message.","minLength":1,"format":"go_template"}}}]}}}}],"properties":{"id":{"type":"string","description":"The alert policy ID.","minLength":1},"created_at":{"type":"integer","description":"The create time of an alert policy."},"updated_at":{"type":"integer","description":"The update time of an alert policy."}}}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["Alert"],"summary":"Create an alert policy.","operationId":"createAlertPolicy","description":"IAM Action: `gateway:CreateAlertPolicy`, Resource: `arn:api7:gateway:alert/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name","trigger_logical_operator","trigger_conditions"],"properties":{"name":{"description":"The alert policy name.","type":"string","minLength":1,"maxLength":100},"desc":{"description":"The alert policy description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"enable":{"type":"boolean","description":"Whether the alert policy is enabled.","default":true},"check_interval":{"type":"integer","description":"The check interval for the alert policy. The unit is second.","minimum":1,"maximum":86400},"severity":{"type":"string","description":"The alert severity level.","default":"medium","enum":["high","medium","low"]},"trigger_logical_operator":{"type":"string","description":"The logical relationship between multiple triggers.","enum":["All","Any"],"default":"All"},"trigger_conditions":{"type":"array","description":"The alert trigger conditions.","minItems":1,"items":{"type":"object","oneOf":[{"title":"Status Code","properties":{"event":{"type":"string","enum":["number_of_status_code","ratio_of_status_code"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"event_config":{"type":"object","properties":{"duration":{"type":"integer","description":"The duration time.","minimum":1},"unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]},"http_status_code":{"type":"string","description":"The HTTP status code.","pattern":"[2-5]\\d{2}|[2-5]xx"}},"required":["http_status_code","duration","unit"]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"}},"required":["event","event_config","operator","value","scope"]},{"title":"Certificate Expiry","properties":{"event":{"type":"string","enum":["ssl_certificate_will_expire_in","gateway_certificate_will_expire_in"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Gateway Instance Offline","properties":{"event":{"type":"string","enum":["gateway_instance_offline"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["equal","larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Dataplane Cores Exceeded","properties":{"event":{"type":"string","enum":["dp_core_exceeded"],"description":"The event of trigger."}}},{"title":"Numbers of Healthy Gateway Instances","properties":{"event":{"type":"string","enum":["number_of_healthy_gateway_instances"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"],"default":"less_equal"},"value":{"type":"integer","format":"int64"}},"required":["event","scope","operator","value"]}]}},"notifications":{"type":"array","description":"The alert notifications.","items":{"type":"object","required":["type"],"oneOf":[{"type":"object","required":["type","subject","content"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["email"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"subject":{"type":"string","description":"The email subject.","minLength":1},"content":{"type":"string","description":"The email content.","minLength":1,"format":"go_template"}}},{"type":"object","required":["type","alert_message"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["webhook"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"alert_message":{"type":"string","description":"The alert message.","minLength":1,"format":"go_template"}}}]}}}}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The definition of an alert policy.","type":"object","allOf":[{"type":"object","required":["name","trigger_logical_operator","trigger_conditions"],"properties":{"name":{"description":"The alert policy name.","type":"string","minLength":1,"maxLength":100},"desc":{"description":"The alert policy description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"enable":{"type":"boolean","description":"Whether the alert policy is enabled.","default":true},"check_interval":{"type":"integer","description":"The check interval for the alert policy. The unit is second.","minimum":1,"maximum":86400},"severity":{"type":"string","description":"The alert severity level.","default":"medium","enum":["high","medium","low"]},"trigger_logical_operator":{"type":"string","description":"The logical relationship between multiple triggers.","enum":["All","Any"],"default":"All"},"trigger_conditions":{"type":"array","description":"The alert trigger conditions.","minItems":1,"items":{"type":"object","oneOf":[{"title":"Status Code","properties":{"event":{"type":"string","enum":["number_of_status_code","ratio_of_status_code"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"event_config":{"type":"object","properties":{"duration":{"type":"integer","description":"The duration time.","minimum":1},"unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]},"http_status_code":{"type":"string","description":"The HTTP status code.","pattern":"[2-5]\\d{2}|[2-5]xx"}},"required":["http_status_code","duration","unit"]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"}},"required":["event","event_config","operator","value","scope"]},{"title":"Certificate Expiry","properties":{"event":{"type":"string","enum":["ssl_certificate_will_expire_in","gateway_certificate_will_expire_in"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Gateway Instance Offline","properties":{"event":{"type":"string","enum":["gateway_instance_offline"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["equal","larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Dataplane Cores Exceeded","properties":{"event":{"type":"string","enum":["dp_core_exceeded"],"description":"The event of trigger."}}},{"title":"Numbers of Healthy Gateway Instances","properties":{"event":{"type":"string","enum":["number_of_healthy_gateway_instances"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"],"default":"less_equal"},"value":{"type":"integer","format":"int64"}},"required":["event","scope","operator","value"]}]}},"notifications":{"type":"array","description":"The alert notifications.","items":{"type":"object","required":["type"],"oneOf":[{"type":"object","required":["type","subject","content"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["email"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"subject":{"type":"string","description":"The email subject.","minLength":1},"content":{"type":"string","description":"The email content.","minLength":1,"format":"go_template"}}},{"type":"object","required":["type","alert_message"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["webhook"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"alert_message":{"type":"string","description":"The alert message.","minLength":1,"format":"go_template"}}}]}}}}],"properties":{"id":{"type":"string","description":"The alert policy ID.","minLength":1},"created_at":{"type":"integer","description":"The create time of an alert policy."},"updated_at":{"type":"integer","description":"The update time of an alert policy."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/alert/policies/{alert_policy_id}":{"parameters":[{"name":"alert_policy_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"tags":["Alert"],"summary":"Get an alert policy.","operationId":"getAlertPolicy","description":"IAM Action: `gateway:GetAlertPolicy`, Resource: `arn:api7:gateway:alert/%s`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The definition of an alert policy.","type":"object","allOf":[{"type":"object","required":["name","trigger_logical_operator","trigger_conditions"],"properties":{"name":{"description":"The alert policy name.","type":"string","minLength":1,"maxLength":100},"desc":{"description":"The alert policy description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"enable":{"type":"boolean","description":"Whether the alert policy is enabled.","default":true},"check_interval":{"type":"integer","description":"The check interval for the alert policy. The unit is second.","minimum":1,"maximum":86400},"severity":{"type":"string","description":"The alert severity level.","default":"medium","enum":["high","medium","low"]},"trigger_logical_operator":{"type":"string","description":"The logical relationship between multiple triggers.","enum":["All","Any"],"default":"All"},"trigger_conditions":{"type":"array","description":"The alert trigger conditions.","minItems":1,"items":{"type":"object","oneOf":[{"title":"Status Code","properties":{"event":{"type":"string","enum":["number_of_status_code","ratio_of_status_code"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"event_config":{"type":"object","properties":{"duration":{"type":"integer","description":"The duration time.","minimum":1},"unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]},"http_status_code":{"type":"string","description":"The HTTP status code.","pattern":"[2-5]\\d{2}|[2-5]xx"}},"required":["http_status_code","duration","unit"]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"}},"required":["event","event_config","operator","value","scope"]},{"title":"Certificate Expiry","properties":{"event":{"type":"string","enum":["ssl_certificate_will_expire_in","gateway_certificate_will_expire_in"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Gateway Instance Offline","properties":{"event":{"type":"string","enum":["gateway_instance_offline"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["equal","larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Dataplane Cores Exceeded","properties":{"event":{"type":"string","enum":["dp_core_exceeded"],"description":"The event of trigger."}}},{"title":"Numbers of Healthy Gateway Instances","properties":{"event":{"type":"string","enum":["number_of_healthy_gateway_instances"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"],"default":"less_equal"},"value":{"type":"integer","format":"int64"}},"required":["event","scope","operator","value"]}]}},"notifications":{"type":"array","description":"The alert notifications.","items":{"type":"object","required":["type"],"oneOf":[{"type":"object","required":["type","subject","content"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["email"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"subject":{"type":"string","description":"The email subject.","minLength":1},"content":{"type":"string","description":"The email content.","minLength":1,"format":"go_template"}}},{"type":"object","required":["type","alert_message"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["webhook"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"alert_message":{"type":"string","description":"The alert message.","minLength":1,"format":"go_template"}}}]}}}}],"properties":{"id":{"type":"string","description":"The alert policy ID.","minLength":1},"created_at":{"type":"integer","description":"The create time of an alert policy."},"updated_at":{"type":"integer","description":"The update time of an alert policy."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Alert"],"summary":"Delete an alert policy.","operationId":"deleteAlertPolicy","description":"IAM Action: `gateway:DeleteAlertPolicy`, Resource: `arn:api7:gateway:alert/%s`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Alert"],"summary":"Update an alert policy.","operationId":"putAlertPolicy","description":"IAM Action: `gateway:UpdateAlertPolicy`, Resource: `arn:api7:gateway:alert/%s`","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name","trigger_logical_operator","trigger_conditions"],"properties":{"name":{"description":"The alert policy name.","type":"string","minLength":1,"maxLength":100},"desc":{"description":"The alert policy description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"enable":{"type":"boolean","description":"Whether the alert policy is enabled.","default":true},"check_interval":{"type":"integer","description":"The check interval for the alert policy. The unit is second.","minimum":1,"maximum":86400},"severity":{"type":"string","description":"The alert severity level.","default":"medium","enum":["high","medium","low"]},"trigger_logical_operator":{"type":"string","description":"The logical relationship between multiple triggers.","enum":["All","Any"],"default":"All"},"trigger_conditions":{"type":"array","description":"The alert trigger conditions.","minItems":1,"items":{"type":"object","oneOf":[{"title":"Status Code","properties":{"event":{"type":"string","enum":["number_of_status_code","ratio_of_status_code"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"event_config":{"type":"object","properties":{"duration":{"type":"integer","description":"The duration time.","minimum":1},"unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]},"http_status_code":{"type":"string","description":"The HTTP status code.","pattern":"[2-5]\\d{2}|[2-5]xx"}},"required":["http_status_code","duration","unit"]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"}},"required":["event","event_config","operator","value","scope"]},{"title":"Certificate Expiry","properties":{"event":{"type":"string","enum":["ssl_certificate_will_expire_in","gateway_certificate_will_expire_in"],"description":"The event of the trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Gateway Instance Offline","properties":{"event":{"type":"string","enum":["gateway_instance_offline"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["equal","larger_equal","larger_than"]},"value":{"type":"integer","format":"int64"},"value_unit":{"type":"string","description":"The duration unit.","enum":["hour","minute","second","year","month","day"]}},"required":["event","operator","value","value_unit","scope"]},{"title":"Dataplane Cores Exceeded","properties":{"event":{"type":"string","enum":["dp_core_exceeded"],"description":"The event of trigger."}}},{"title":"Numbers of Healthy Gateway Instances","properties":{"event":{"type":"string","enum":["number_of_healthy_gateway_instances"],"description":"The event of trigger."},"scope":{"type":"object","properties":{"gateway_group_ids":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"gateway_group_labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}},"oneOf":[{"required":["gateway_group_ids"]},{"required":["gateway_group_labels"]}]},"operator":{"type":"string","description":"The operator for the trigger condition.","enum":["less_equal","less_than"],"default":"less_equal"},"value":{"type":"integer","format":"int64"}},"required":["event","scope","operator","value"]}]}},"notifications":{"type":"array","description":"The alert notifications.","items":{"type":"object","required":["type"],"oneOf":[{"type":"object","required":["type","subject","content"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["email"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"subject":{"type":"string","description":"The email subject.","minLength":1},"content":{"type":"string","description":"The email content.","minLength":1,"format":"go_template"}}},{"type":"object","required":["type","alert_message"],"properties":{"type":{"type":"string","description":"The notification type.","enum":["webhook"]},"contact_point_ids":{"type":"array","uniqueItems":true,"items":{"minLength":1,"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","maxLength":256}},"alert_message":{"type":"string","description":"The alert message.","minLength":1,"format":"go_template"}}}]}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Alert"],"summary":"Patch an alert policy.","operationId":"patchAlertPolicy","description":"IAM Action: `gateway:UpdateAlertPolicy`, Resource: `arn:api7:gateway:alert/%s`","requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/alert/policies/histories":{"get":{"tags":["Alert"],"summary":"List all alert histories.","operationId":"listAlertHistory","description":"IAM Action: `gateway:GetAlertPolicy`, Resource: `arn:api7:gateway:alert/*`","parameters":[{"name":"alert_policy_id","in":"query","schema":{"type":"string"}},{"name":"severity","in":"query","required":false,"schema":{"type":"array","items":{"type":"string","enum":["high","medium","low"]}}},{"in":"query","name":"start_at","schema":{"type":"integer"}},{"in":"query","name":"end_at","schema":{"type":"integer"}},{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}},{"name":"order_by","in":"query","schema":{"type":"string","default":"alert_time","enum":["alert_time"]}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of alert policy history.","items":{"type":"object","description":"","properties":{"id":{"type":"string","minLength":1},"alert_policy_id":{"type":"string","minLength":1},"alert_policy_name":{"type":"string","description":"The alert policy name."},"trigger_gateway_groups":{"type":"array","items":{"type":"object","properties":{"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100}}}},"severity":{"type":"string","description":"The alert severity level.","enum":["high","medium","low"]},"alert_time":{"type":"integer","description":"The alert time."},"alert_detail":{"type":"string","description":"The alert detail."},"notification_logs":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"},"contact_point_name":{"type":"string"},"resource_type":{"type":"string","enum":["alert_policy","api_product_notification"]},"resource_id":{"type":"string"},"resource_name":{"type":"string"},"status":{"type":"string"},"send_time":{"type":"integer"},"request":{"type":"string"},"response":{"type":"string"}}}},"created_at":{"type":"integer","description":"The create time of an alert policy."},"updated_at":{"type":"integer","description":"The update time of an alert policy."}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/audit_logs":{"get":{"tags":["Audit Logs"],"summary":"List all audit logs.","operationId":"listAuditLogs","description":"IAM Action: `iam:GetAudit`, Resource: `arn:api7:iam:organization/*`","parameters":[{"name":"event_type","in":"query","schema":{"type":"string"}},{"name":"operator_id","description":"The user ID of the operator.","in":"query","schema":{"type":"string"}},{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}},{"name":"resource_id","in":"query","schema":{"type":"string"}},{"in":"query","name":"start_at","schema":{"type":"integer"}},{"in":"query","name":"end_at","schema":{"type":"integer"}},{"name":"order_by","in":"query","schema":{"type":"string","default":"event_time","enum":["event_time"]}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of audit logs.","items":{"type":"object","properties":{"id":{"type":"string"},"event_time":{"description":"The object timestamp.","type":"integer","minimum":0},"operator_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"operator":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"username":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"email_verified":{"type":"boolean"}}},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"source":{"type":"string","enum":["dashboard","api"]},"token_name":{"type":"string","description":"The name of the token used for authentication."},"event_type":{"type":"string"},"resource_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ip_address":{"type":"string"},"error_message":{"type":"string"},"http_request":{"type":"object","properties":{"method":{"type":"string"},"uri":{"type":"string"},"body":{"type":"object"},"user_agent":{"type":"string"}}},"http_response":{"type":"object","properties":{"status_code":{"type":"integer"},"body":{"type":"object"}}}}}}}}]}}}}}}},"/api/audit_logs/event_types":{"get":{"tags":["Audit Logs"],"summary":"List all event types of audit logs.","operationId":"listAuditLogEventTypes","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of event types of audit logs.","items":{"type":"object","properties":{"key":{"type":"string","description":"The key of the audit log event type."},"name":{"type":"string","description":"The name of the audit log event type."}}}}}}]}}}}}}},"/api/audit_logs/export":{"get":{"tags":["Audit Logs"],"summary":"Export all audit logs.","operationId":"exportAuditLogs","description":"IAM Action: `iam:ExportAudits`, Resource: `arn:api7:iam:organization/*`","parameters":[{"name":"event_type","in":"query","schema":{"type":"string"}},{"name":"operator_id","description":"The user ID of the operator.","in":"query","schema":{"type":"string"}},{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}},{"name":"resource_id","in":"query","schema":{"type":"string"}},{"in":"query","name":"start_at","schema":{"type":"integer"}},{"in":"query","name":"end_at","schema":{"type":"integer"}},{"in":"query","name":"format","required":true,"schema":{"type":"string","enum":["json","csv"]}}],"responses":{"200":{"description":"","content":{"application/json":{},"text/csv":{}}}}}},"/api/tokens":{"post":{"tags":["Token"],"summary":"Create a token.","operationId":"createToken","requestBody":{"content":{"application/json":{"schema":{"description":"Create a token.","type":"object","required":["name","expires_at"],"properties":{"name":{"type":"string","description":"The token name.","maxLength":40},"expires_at":{"type":"integer","format":"int64","description":"The expiration time of the token."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","properties":{"id":{"type":"string","description":"The token ID."},"name":{"type":"string","description":"The token name."},"created_at":{"type":"integer","format":"int64","description":"The time when a token is created."},"updated_at":{"type":"integer","format":"int64","description":"The time when a token is updated."},"expires_at":{"type":"integer","format":"int64","description":"The expiration time of the token."},"user_id":{"type":"string","description":"The user ID."},"user_name":{"type":"string","description":"The user name."},"last_used_at":{"type":"integer","format":"int64","description":"The last time when the token is used."}}},{"type":"object","properties":{"token":{"type":"string"}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Token"],"summary":"List all tokens.","operationId":"listTokens","parameters":[{"name":"order_by","in":"query","schema":{"type":"string","default":"created_at","enum":["created_at","updated_at","expires_at"]}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of tokens.","items":{"type":"object","properties":{"id":{"type":"string","description":"The token ID."},"name":{"type":"string","description":"The token name."},"created_at":{"type":"integer","format":"int64","description":"The time when a token is created."},"updated_at":{"type":"integer","format":"int64","description":"The time when a token is updated."},"expires_at":{"type":"integer","format":"int64","description":"The expiration time of the token."},"user_id":{"type":"string","description":"The user ID."},"user_name":{"type":"string","description":"The user name."},"last_used_at":{"type":"integer","format":"int64","description":"The last time when the token is used."}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/tokens/{token_id}":{"parameters":[{"name":"token_id","description":"The unique identifier of the token.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"get":{"tags":["Token"],"summary":"Get a token.","operationId":"getToken","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"type":"string","description":"The token ID."},"name":{"type":"string","description":"The token name."},"created_at":{"type":"integer","format":"int64","description":"The time when a token is created."},"updated_at":{"type":"integer","format":"int64","description":"The time when a token is updated."},"expires_at":{"type":"integer","format":"int64","description":"The expiration time of the token."},"user_id":{"type":"string","description":"The user ID."},"user_name":{"type":"string","description":"The user name."},"last_used_at":{"type":"integer","format":"int64","description":"The last time when the token is used."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Token"],"summary":"Update a token.","operationId":"updateToken","requestBody":{"content":{"application/json":{"schema":{"description":"Update a token.","type":"object","required":["name"],"properties":{"name":{"type":"string","description":"The token name.","maxLength":40}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"type":"string","description":"The token ID."},"name":{"type":"string","description":"The token name."},"created_at":{"type":"integer","format":"int64","description":"The time when a token is created."},"updated_at":{"type":"integer","format":"int64","description":"The time when a token is updated."},"expires_at":{"type":"integer","format":"int64","description":"The expiration time of the token."},"user_id":{"type":"string","description":"The user ID."},"user_name":{"type":"string","description":"The user name."},"last_used_at":{"type":"integer","format":"int64","description":"The last time when the token is used."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Token"],"summary":"Delete a token.","operationId":"deleteToken","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/tokens/{token_id}/regenerate":{"parameters":[{"name":"token_id","description":"The unique identifier of the token.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"put":{"tags":["Token"],"summary":"Regenerate a token.","operationId":"regenerateToken","requestBody":{"content":{"application/json":{"schema":{"description":"Regenerate a token.","type":"object","required":["expires_at"],"properties":{"expires_at":{"type":"integer","format":"int64","description":"The expiration time of the token."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","properties":{"id":{"type":"string","description":"The token ID."},"name":{"type":"string","description":"The token name."},"created_at":{"type":"integer","format":"int64","description":"The time when a token is created."},"updated_at":{"type":"integer","format":"int64","description":"The time when a token is updated."},"expires_at":{"type":"integer","format":"int64","description":"The expiration time of the token."},"user_id":{"type":"string","description":"The user ID."},"user_name":{"type":"string","description":"The user name."},"last_used_at":{"type":"integer","format":"int64","description":"The last time when the token is used."}}},{"type":"object","properties":{"token":{"type":"string"}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups":{"get":{"tags":["Gateway Group"],"summary":"List all gateway groups.","operationId":"listGatewayGroups","description":"IAM Action: `gateway:GetGatewayGroup`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of gateway groups.","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"type":{"type":"string","enum":["api7_gateway","api7_ingress_controller"]},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}},"enforce_service_publishing":{"type":"boolean","description":"Updating services directly on a gateway group bypass version control and rollback capabilities.\n"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"config":{"type":"object","properties":{"control_plane_key_prefix":{"type":"string","description":"The prefix of the key in the control plane (etcd). The pattern is \"/gateway_groups/{short_id}\".\nThe \"short_id\" is one-to-one correspondence for \"gateway_group_id\"."},"control_plane_user":{"type":"string","description":"The etcd user."},"control_plane_password":{"type":"string","description":"The etcd password."},"image_tag":{"type":"string","description":"The API7 gateway version."}}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["Gateway Group"],"summary":"Create a gateway group.","operationId":"createGatewayGroup","description":"IAM Action: `gateway:CreateGatewayGroup`, Resource: `arn:api7:gateway:gatewaygroup/%s`","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"type":{"default":"api7_gateway","type":"string","enum":["api7_gateway","api7_ingress_controller"]},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"enforce_service_publishing":{"type":"boolean","description":"Updating services directly on a gateway group bypass version control and rollback capabilities.\n"}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"type":{"type":"string","enum":["api7_gateway","api7_ingress_controller"]},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}},"enforce_service_publishing":{"type":"boolean","description":"Updating services directly on a gateway group bypass version control and rollback capabilities.\n"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"config":{"type":"object","properties":{"control_plane_key_prefix":{"type":"string","description":"The prefix of the key in the control plane (etcd). The pattern is \"/gateway_groups/{short_id}\".\nThe \"short_id\" is one-to-one correspondence for \"gateway_group_id\"."},"control_plane_user":{"type":"string","description":"The etcd user."},"control_plane_password":{"type":"string","description":"The etcd password."},"image_tag":{"type":"string","description":"The API7 gateway version."}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/count/{resource_type}":{"get":{"tags":["Gateway Group"],"summary":"Count resources for the gateway group.","operationId":"countResourceByGatewayGroup","parameters":[{"name":"resource_type","in":"path","required":true,"schema":{"type":"string","enum":["ssl","consumer","gateway_instance"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","items":{"allOf":[{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"type":{"type":"string","enum":["api7_gateway","api7_ingress_controller"]},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}},"enforce_service_publishing":{"type":"boolean","description":"Updating services directly on a gateway group bypass version control and rollback capabilities.\n"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"config":{"type":"object","properties":{"control_plane_key_prefix":{"type":"string","description":"The prefix of the key in the control plane (etcd). The pattern is \"/gateway_groups/{short_id}\".\nThe \"short_id\" is one-to-one correspondence for \"gateway_group_id\"."},"control_plane_user":{"type":"string","description":"The etcd user."},"control_plane_password":{"type":"string","description":"The etcd password."},"image_tag":{"type":"string","description":"The API7 gateway version."}}}}},{"type":"object","properties":{"count":{"type":"integer"}}}]}}}}]}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/ssls/{ssl_id}/usage":{"get":{"tags":["Gateway Group"],"summary":"List SSL Usage in a gateway group","operationId":"listSSLUsages","description":"IAM Action: `gateway:GetSSLCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"ssl_id","description":"The unique identifier of the SSL object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of SSL Usage.","items":{"description":"ssl usage response","type":"object","allOf":[{"type":"object","properties":{"service_id":{"type":"string","description":"service template id"},"service_name":{"type":"string","description":"service name"},"gateway_group_id":{"type":"string","description":"gateway group id"},"upstream_name":{"type":"string","description":"upstream name which use ssl"},"ssl_id":{"type":"string","description":"ssl id which upstream use"}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/snis/{sni_id}/usage":{"get":{"tags":["Gateway Group"],"summary":"List SNI Usage in a gateway group","operationId":"listSNIUsages","description":"IAM Action: `gateway:GetSNI`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"sni_id","description":"The unique identifier of the SNI object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of SNI Usage.","items":{"type":"object","properties":{"service_id":{"type":"string","description":"service template id"},"service_name":{"type":"string","description":"service name"},"hosts":{"type":"array","description":"hosts which related to sni","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/certificates/{certificate_id}/usage":{"get":{"tags":["Gateway Group"],"summary":"List Certificate Usage in a gateway group","operationId":"listCertificateUsages","description":"IAM Action: `gateway:GetCertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s` ","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"resource_type","in":"query","required":false,"description":"Type of resource referencing the certificate.","schema":{"type":"string","enum":["sni","upstream"],"default":"sni"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of SNI Usage.","items":{"oneOf":[{"title":"SNI","type":"object","properties":{"resource_type":{"type":"string","enum":["sni"]},"sni_id":{"type":"string","description":"sni id"},"sni_name":{"type":"string","description":"sni name"},"service_id":{"type":"string","description":"service template id"},"service_name":{"type":"string","description":"service name"},"hosts":{"type":"array","description":"hosts which related to sni","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}}}},{"title":"Upstream","type":"object","properties":{"resource_type":{"type":"string","enum":["upstream"]},"upstream_id":{"type":"string"},"upstream_name":{"type":"string"},"service_id":{"type":"string","description":"service template id"},"service_name":{"type":"string","description":"service name"}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/ca_certificates/{ca_certificate_id}/usage":{"get":{"tags":["Gateway Group"],"summary":"List CA Certificate Usage in a gateway group","operationId":"listCACertificateUsages","description":"IAM Action: `gateway:GetCACertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"ca_certificate_id","description":"The unique identifier of the Certificate object.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"resource_type","in":"query","required":false,"description":"Type of resource referencing the certificate.","schema":{"type":"string","enum":["sni","upstream"],"default":"sni"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of SNI Usage.","items":{"oneOf":[{"title":"SNI","type":"object","properties":{"resource_type":{"type":"string","enum":["sni"]},"sni_id":{"type":"string","description":"sni id"},"sni_name":{"type":"string","description":"sni name"},"service_id":{"type":"string","description":"service template id"},"service_name":{"type":"string","description":"service name"},"hosts":{"type":"array","description":"hosts which related to sni","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}}}},{"title":"Upstream","type":"object","properties":{"resource_type":{"type":"string","enum":["upstream"]},"upstream_id":{"type":"string"},"upstream_name":{"type":"string"},"service_id":{"type":"string","description":"service template id"},"service_name":{"type":"string","description":"service name"}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/certificates/exists":{"post":{"tags":["Gateway Group"],"summary":"Check if a certificate exists in a gateway group","description":"IAM Action: `gateway:GetCACertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","operationId":"checkCertificateExists","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"common_name":{"type":"string","description":"The common name of the certificate."},"subject_alt_names":{"type":"array","description":"The subject alternative names of the certificate.","items":{"type":"string"}},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"404":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/ca_certificates/exists":{"post":{"tags":["Gateway Group"],"summary":"Check if a CA certificate exists in a gateway group","description":"IAM Action: `gateway:GetCACertificate`, Resource: `arn:api7:gateway:gatewaygroup/%s`","operationId":"checkCACertificateExists","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The Certificate response format, with filtering the sensitive fields\nand some other fields.","type":"object","allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"desc":{"description":"The object description.","type":"string","maxLength":65536},"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"associated_snis":{"type":"array","description":"The sni ids associated with the certificate.","items":{"type":"string"}},"exptime":{"type":"integer","description":"The SSL certificate expire time."},"validity_start":{"type":"integer","description":"The earliest time when the SSL certificate is used."},"validity_end":{"type":"integer","description":"The latest time when the SSL certificate is used."}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"404":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/secret_providers/{secret_manager}/{secret_provider_id}/usage":{"get":{"tags":["Gateway Group"],"summary":"List Secret Provider Usage in a gateway group","operationId":"listSecretProviderUsages","description":"IAM Action: `gateway:GetSecretProvider`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"secret_manager","in":"path","required":true,"schema":{"type":"string","enum":["vault","aws","kubernetes"]}},{"name":"secret_provider_id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":256}},{"name":"resource_type","in":"query","required":false,"schema":{"type":"string","enum":["consumer","service","route","ssl","global_rule","consumer_credential","certificate"]}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of Secret Usage.","items":{"description":"secret usage response","type":"object","allOf":[{"type":"object","properties":{"parent_id":{"type":"string","description":"parent id, provided for the route/consumer_credential resource type"},"resource_type":{"type":"string","description":"resource type which use secret"},"resource_id":{"type":"string","description":"resource id which use secret"},"resource_name":{"type":"string","description":"resource name"},"gateway_group_id":{"type":"string","description":"gateway group id"},"field":{"type":"string","description":"secret usage field"},"id":{"type":"string","description":"secret provider id"},"secret_manager":{"type":"string","description":"secret manager, like vault"}}},{"type":"object","properties":{"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}":{"delete":{"tags":["Gateway Group"],"summary":"Delete a gateway group.","operationId":"deleteGatewayGroup","description":"IAM Action: `gateway:DeleteGatewayGroup`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Gateway Group"],"summary":"Update a gateway group.","operationId":"putGatewayGroup","description":"IAM Action: `gateway:UpdateGatewayGroup`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name","description"],"properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}}}}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"type":{"type":"string","enum":["api7_gateway","api7_ingress_controller"]},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}},"enforce_service_publishing":{"type":"boolean","description":"Updating services directly on a gateway group bypass version control and rollback capabilities.\n"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"config":{"type":"object","properties":{"control_plane_key_prefix":{"type":"string","description":"The prefix of the key in the control plane (etcd). The pattern is \"/gateway_groups/{short_id}\".\nThe \"short_id\" is one-to-one correspondence for \"gateway_group_id\"."},"control_plane_user":{"type":"string","description":"The etcd user."},"control_plane_password":{"type":"string","description":"The etcd password."},"image_tag":{"type":"string","description":"The API7 gateway version."}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Gateway Group"],"summary":"Get a gateway group.","operationId":"getGatewayGroup","description":"IAM Action: `gateway:GetGatewayGroup`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"type":{"type":"string","enum":["api7_gateway","api7_ingress_controller"]},"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"labels":{"type":"object","additionalProperties":{"type":"string"}},"enforce_service_publishing":{"type":"boolean","description":"Updating services directly on a gateway group bypass version control and rollback capabilities.\n"},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"config":{"type":"object","properties":{"control_plane_key_prefix":{"type":"string","description":"The prefix of the key in the control plane (etcd). The pattern is \"/gateway_groups/{short_id}\".\nThe \"short_id\" is one-to-one correspondence for \"gateway_group_id\"."},"control_plane_user":{"type":"string","description":"The etcd user."},"control_plane_password":{"type":"string","description":"The etcd password."},"image_tag":{"type":"string","description":"The API7 gateway version."}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/admin_key":{"put":{"tags":["Gateway Group"],"summary":"Generate an admin key for a gateway group.","operationId":"generateAdminKey","description":"IAM Action: `gateway:UpdateGatewayGroup`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"key":{"type":"string","description":"The admin key in plain text."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/deployment/docker":{"get":{"tags":["Gateway Group","Gateway Instance"],"summary":"Generate script to install the gateway instance by Docker.","operationId":"generateInstallScriptForDocker","description":"IAM Action: `gateway:CreateGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"control_plane_address","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"image","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"http_port","in":"query","required":false,"schema":{"type":"integer","default":9080}},{"name":"https_port","in":"query","required":false,"schema":{"type":"integer","default":9443}},{"name":"name","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"extra_args[]","description":"Additional docker run arguments.","in":"query","required":false,"schema":{"type":"array","items":{"type":"string","minLength":1}}}],"responses":{"200":{"description":"","content":{"text/plain":{"schema":{"type":"string"}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/deployment/helm/script":{"get":{"tags":["Gateway Group","Gateway Instance"],"summary":"Generate script to install the gateway instance by Helm in Kubernetes.","operationId":"generateInstallScriptForHelm","description":"IAM Action: `gateway:CreateGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"control_plane_address","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"name","in":"query","required":true,"schema":{"type":"string"}},{"name":"namespace","in":"query","required":true,"schema":{"type":"string"}},{"name":"service_account","in":"query","required":false,"schema":{"type":"string"}},{"name":"replicas","in":"query","required":false,"schema":{"type":"integer","default":1}},{"name":"workers","in":"query","required":false,"schema":{"type":"integer"}},{"name":"cpu_limit","in":"query","required":false,"schema":{"type":"string"}},{"name":"memory_limit","in":"query","required":false,"schema":{"type":"string"}},{"name":"extra_values[]","description":"extra values to be passed to the helm chart, in the form of key=value","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}}}],"responses":{"200":{"description":"","content":{"text/plain":{"schema":{"type":"string"}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/deployment/helm/yaml":{"get":{"tags":["Gateway Group","Gateway Instance"],"summary":"Generate values.yaml to install the gateway instance by Helm in Kubernetes.","operationId":"generateInstallYamlForHelm","description":"IAM Action: `gateway:CreateGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"control_plane_address","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"name","in":"query","required":true,"schema":{"type":"string"}},{"name":"namespace","in":"query","required":true,"schema":{"type":"string"}},{"name":"service_account","in":"query","required":false,"schema":{"type":"string"}},{"name":"replicas","in":"query","required":false,"schema":{"type":"integer","default":1}},{"name":"workers","in":"query","required":false,"schema":{"type":"integer"}},{"name":"cpu_limit","in":"query","required":false,"schema":{"type":"string"}},{"name":"memory_limit","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"text/plain":{"schema":{"type":"string"}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/instances/{gateway_instance_id}":{"delete":{"tags":["Gateway Instance"],"summary":"Delete gateway instance.","operationId":"deleteGatewayInstance","description":"IAM Action: `gateway:DeleteGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_instance_id","in":"path","required":true,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/dp_client_certificates":{"post":{"tags":["Gateway Instance","Gateway Group"],"summary":"Issue a data plane certificate on a gateway group.","operationId":"issueDataplaneCertificate","description":"IAM Action: `gateway:CreateGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"certificate":{"type":"string"},"private_key":{"type":"string"},"expiry":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}]}}}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services":{"get":{"tags":["Gateway Group","Published Service"],"deprecated":true,"summary":"List all published services in a gateway group.","operationId":"listPublishedServicesDeprecated","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s` Deprecated, you can use `GET /apisix/admin/services` for instead.","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"runtime_type","in":"query","schema":{"type":"string","enum":["normal","canary"]}},{"name":"unhealthy_nodes","in":"query","schema":{"type":"array","items":{"type":"string","enum":["unhealthy_nodes_exists","no_unhealthy_nodes"]}}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","publish_time","name"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"hosts","in":"query","schema":{"type":"array","items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}}},{"name":"type","in":"query","schema":{"type":"array","items":{"type":"string","enum":["http","stream"]}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of published services.","items":{"allOf":[{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"unhealthy_nodes_count":{"type":"integer"},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}":{"get":{"tags":["Gateway Group","Published Service"],"summary":"Get a published service on a gateway group.","operationId":"getPublishedServiceByServiceTemplateID","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"unhealthy_nodes_count":{"type":"integer"},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Gateway Group","Published Service"],"summary":"Delete a published service on a gateway group.","operationId":"deletePublishedServiceByServiceTemplateID","description":"IAM Action: `gateway:DeletePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/oas":{"get":{"tags":["Gateway Group","Published Service"],"summary":"Get the OpenAPI Specification of a published service on a gateway group.","operationId":"getPublishedServiceOASByServiceTemplateID","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"raw_openapi":{"type":"string","description":"The OpenAPI specification of the service."},"api_count":{"type":"integer","description":"The number of APIs in the service."},"api_desc":{"type":"string","description":"The description of the OAS."}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Gateway Group","Published Service"],"summary":"Update the OpenAPI Specification of a published service on a gateway group.","operationId":"putPublishedServiceOASByServiceTemplateID","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"raw_openapi":{"type":"string","description":"The raw OpenAPI specification of the service."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"raw_openapi":{"type":"string","description":"The OpenAPI specification of the service."},"api_count":{"type":"integer","description":"The number of APIs in the service."},"api_desc":{"type":"string","description":"The description of the OAS."}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/routes":{"get":{"tags":["Gateway Group","Published Service"],"summary":"List all routes of published service on a gateway group.","operationId":"listPublishedServiceRoutesByServiceTemplateID","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of route versions.","items":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/routes/{route_template_id}":{"get":{"tags":["Gateway Group","Published Service","Route"],"summary":"Get a route in a published service on a gateway group.","operationId":"getPublishedServiceRouteByServiceTemplateID","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"route_template_id","description":"The unique identifier of the route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/routes/{route_template_id}/runtime_configuration":{"get":{"tags":["Gateway Group","Published Service"],"summary":"Get the runtime configuration of a route in a published service on a gateway group.","operationId":"getPublishedRouteRuntimeConfiguration","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"route_template_id","description":"The unique identifier of the route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Gateway Group","Published Service"],"summary":"Update the runtime configuration of a route in a published service on a gateway group.","operationId":"patchPublishedRouteRuntimeConfiguration","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"route_template_id","description":"The unique identifier of the route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/stream_routes":{"get":{"tags":["Gateway Group","Published Service","Stream Route"],"summary":"List all stream routes of a published service on a gateway group.","operationId":"listPublishedServiceStreamRoutesByServiceTemplateID","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of route versions.","items":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"stream_route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/stream_routes/{stream_route_template_id}":{"get":{"tags":["Gateway Group","Published Service","Stream Route"],"summary":"Get a stream route in a published service on a gateway group.","operationId":"getPublishedServiceStreamRouteByServiceTemplateID","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"stream_route_template_id","description":"The unique identifier of the stream route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"stream_route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/stream_routes/{stream_route_template_id}/runtime_configuration":{"get":{"tags":["Gateway Group","Published Service"],"summary":"Get the runtime configuration of a stream route in a published service on a gateway group.","operationId":"getPublishedStreamRouteRuntimeConfiguration","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"stream_route_template_id","description":"The unique identifier of the stream route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Gateway Group","Published Service"],"summary":"Update the runtime configuration of a stream route in a published service on a gateway group.","operationId":"patchPublishedStreamRouteRuntimeConfiguration","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"stream_route_template_id","description":"The unique identifier of the stream route template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/versions":{"get":{"tags":["Gateway Group","Published Service"],"summary":"List all history versions of a published services on a gateway group by service ID.","operationId":"listPublishedServiceVersions","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"publish_time","enum":["publish_time"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of published service versions.","items":{"allOf":[{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"publish_time":{"type":"string","description":"The time when a service version is published."}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/runtime_configuration":{"get":{"tags":["Gateway Group","Published Service"],"summary":"Fetch service runtime configurations of a published service on a gateway group.","operationId":"getServiceRuntimeConfiguration","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"oneOf":[{"type":"object","minProperties":1,"properties":{"hosts":{"type":"array","description":"The hosts for the service to accept incoming requests.","uniqueItems":true,"minItems":1,"maxItems":32,"items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"path_prefix":{"maxLength":4096,"minLength":1,"pattern":"^/","type":"string","description":"The listening path prefix of the service."},"strip_path_prefix":{"type":"boolean","default":true,"description":"Weather strip the path prefix or not when proxying the request to the upstream."},"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","minProperties":1,"properties":{"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Gateway Group","Published Service"],"summary":"Update service runtime configurations of a published service on a gateway group.","operationId":"patchServiceRuntimeConfiguration","description":"IAM Action: `gateway:UpdatePublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"in":"query","name":"dry-run","schema":{"type":"string","enum":["all"]},"description":"The flag that indicates whether to run the operation in dry-run mode."}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"oneOf":[{"type":"object","minProperties":1,"properties":{"hosts":{"type":"array","description":"The hosts for the service to accept incoming requests.","uniqueItems":true,"minItems":1,"maxItems":32,"items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"path_prefix":{"maxLength":4096,"minLength":1,"pattern":"^/","type":"string","description":"The listening path prefix of the service."},"strip_path_prefix":{"type":"boolean","default":true,"description":"Weather strip the path prefix or not when proxying the request to the upstream."},"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},{"type":"object","minProperties":1,"properties":{"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/services/{service_template_id}/healthcheck":{"get":{"tags":["Gateway Group","Published Service"],"summary":"Get healthcheck status for the upstream of a published service on a gateway group.","operationId":"getUpstreamHealthcheckStatus","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"The response for retrieving some source's healthcheck status.","content":{"application/json":{"schema":{"type":"object","properties":{"value":{"type":"object","description":"Healthcheck status data for every node.","additionalProperties":{"type":"object","description":"Node's healthcheck status on every gateway instance group by node.","properties":{"host":{"type":"string","example":"httpbin.com"},"port":{"type":"integer","example":80},"total":{"type":"integer","description":"Total number of gateway instances.","example":1},"healthy":{"type":"integer","description":"The number of gateway instances that determine the node is healthy.","example":1},"unhealthy":{"type":"integer","description":"The number of gateway instances that determine the node is unhealthy."},"unknown":{"type":"integer","description":"The number of gateway instances that did not report the check results for this node."},"updated_at":{"description":"The time of the node status updated at.","type":"integer","minimum":0},"gateway_instances":{"type":"array","description":"Each item is a gateway instance's health check count details for the node.","items":{"type":"object","properties":{"id":{"type":"string","description":"The gateway instance id","example":"xxx-yyy-zzz"},"hostname":{"type":"string","description":"instance hostname","example":"api7ee3-apisix-699b68db7f-cxgcw"},"status":{"type":"string","description":"node's health status","enum":["healthy","unhealthy","unknown"],"example":"healthy"},"created_at":{"description":"The time when the data plane first reported the gateway instance’s probe result of the node’s health status.","type":"integer","minimum":0},"updated_at":{"description":"The last time the data plane reported the gateway instance’s probe result of the node’s health status.","type":"integer","minimum":0}}}}}},"example":{"httpbin.com:80":{"host":"httpbin.com","port":80,"total":1,"healthy":1,"unhealthy":0,"unknown":0,"updated_at":0,"gateway_instances":[{"id":"xxx-yyy-zzz","hostname":"api7ee3-apisix-699b68db7f-cxgcw","status":"healthy","created_at":0,"updated_at":0}]}}}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries":{"get":{"tags":["Service Registry","Gateway Group"],"summary":"List all service registry connections on a gateway group.","operationId":"listServiceRegistries","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","last_connect_time"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of service registries.","items":{"allOf":[{"description":"The service registry model.","allOf":[{"type":"object","required":["name","type"],"allOf":[{"type":"object","properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"health_check":{"type":"object","properties":{"probe_interval":{"default":15,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking service registry (in seconds)."},"probe_timeout":{"default":5,"minimum":1,"type":"integer","format":"int64","description":"The timeout for checking service registry (in seconds)."}}}}},{"oneOf":[{"type":"object","required":["type","kubernetes_config"],"properties":{"type":{"type":"string","enum":["kubernetes"],"description":"The kubernetes service type."},"kubernetes_config":{"type":"object","properties":{"service":{"description":"The IP address of the Kubernetes API server.","type":"object","required":["schema","host","port"],"properties":{"schema":{"type":"string","enum":["http","https"]},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"string","minLength":1,"example":"6443"}}},"namespace_selector":{"description":"The namespace selector to filter target namespaces.","type":"object","nullable":true,"properties":{"equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"not_equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1},"not_match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1}},"oneOf":[{"required":["equal"]},{"required":["not_equal"]},{"required":["match"]},{"required":["not_match"]}]},"label_selector":{"description":"The label selector to filter target endpoints.","type":"string"},"client":{"description":"The client name.","oneOf":[{"properties":{"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","pattern":"^[^\\:*?\"<>|]*$"}},"required":["token_file"]},{"properties":{"token":{"description":"The token of the Kubernetes service account.","type":"string","pattern":"^[A-Za-z0-9+\\/._=-]+$"}},"required":["token"]}]}}}}},{"type":"object","required":["type","nacos_config"],"properties":{"type":{"type":"string","enum":["nacos"],"description":"The Nacos service type."},"nacos_config":{"type":"object","required":["hosts"],"properties":{"hosts":{"description":"The address of the Nacos API server.","type":"array","minItems":1,"items":{"type":"string","format":"url"}},"prefix":{"description":"The prefix of the Nacos API.","type":"string","default":"/nacos/v1"},"default_weight":{"type":"integer","description":"The default weight of the endpoints.","minimum":1,"maximum":100,"example":100,"default":100},"fetch_interval":{"type":"integer","description":"The interval for fetching endpoints (in seconds).","example":30,"default":10},"timeout":{"type":"object","description":"The timeout for connecting, sending and reading (in seconds).","properties":{"connect":{"type":"integer","example":2,"default":2},"send":{"type":"integer","example":2,"default":2},"read":{"type":"integer","example":5,"default":5}}},"auth":{"oneOf":[{"properties":{"username":{"description":"The username of the Nacos API.","type":"string","minLength":1},"password":{"description":"The password of the Nacos API.","type":"string","minLength":1}},"required":["username","password"]},{"properties":{"token":{"type":"string","description":"The token of the Nacos service.","minLength":1}},"required":["token"]},{"properties":{"access_key":{"description":"The access key of the Nacos API.","type":"string","minLength":1},"secret_key":{"description":"The secret key of the Nacos API.","type":"string","minLength":1}},"required":["access_key","secret_key"]}]}}}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"status":{"type":"string","enum":["healthy","lost_connection","connecting"],"default":"connecting","description":"The status of the service registry."},"last_connect_time":{"description":"The object timestamp.","type":"integer","minimum":0},"associated_services_count":{"type":"integer","format":"int64","description":"The associated services of the service registry."}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["Service Registry","Gateway Group"],"summary":"Create a service registry connection on a gateway group.","operationId":"createServiceRegistry","description":"IAM Action: `gateway:ConnectServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name","type"],"allOf":[{"type":"object","properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"health_check":{"type":"object","properties":{"probe_interval":{"default":15,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking service registry (in seconds)."},"probe_timeout":{"default":5,"minimum":1,"type":"integer","format":"int64","description":"The timeout for checking service registry (in seconds)."}}}}},{"oneOf":[{"type":"object","required":["type","kubernetes_config"],"properties":{"type":{"type":"string","enum":["kubernetes"],"description":"The kubernetes service type."},"kubernetes_config":{"type":"object","properties":{"service":{"description":"The IP address of the Kubernetes API server.","type":"object","required":["schema","host","port"],"properties":{"schema":{"type":"string","enum":["http","https"]},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"string","minLength":1,"example":"6443"}}},"namespace_selector":{"description":"The namespace selector to filter target namespaces.","type":"object","nullable":true,"properties":{"equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"not_equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1},"not_match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1}},"oneOf":[{"required":["equal"]},{"required":["not_equal"]},{"required":["match"]},{"required":["not_match"]}]},"label_selector":{"description":"The label selector to filter target endpoints.","type":"string"},"client":{"description":"The client name.","oneOf":[{"properties":{"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","pattern":"^[^\\:*?\"<>|]*$"}},"required":["token_file"]},{"properties":{"token":{"description":"The token of the Kubernetes service account.","type":"string","pattern":"^[A-Za-z0-9+\\/._=-]+$"}},"required":["token"]}]}}}}},{"type":"object","required":["type","nacos_config"],"properties":{"type":{"type":"string","enum":["nacos"],"description":"The Nacos service type."},"nacos_config":{"type":"object","required":["hosts"],"properties":{"hosts":{"description":"The address of the Nacos API server.","type":"array","minItems":1,"items":{"type":"string","format":"url"}},"prefix":{"description":"The prefix of the Nacos API.","type":"string","default":"/nacos/v1"},"default_weight":{"type":"integer","description":"The default weight of the endpoints.","minimum":1,"maximum":100,"example":100,"default":100},"fetch_interval":{"type":"integer","description":"The interval for fetching endpoints (in seconds).","example":30,"default":10},"timeout":{"type":"object","description":"The timeout for connecting, sending and reading (in seconds).","properties":{"connect":{"type":"integer","example":2,"default":2},"send":{"type":"integer","example":2,"default":2},"read":{"type":"integer","example":5,"default":5}}},"auth":{"oneOf":[{"properties":{"username":{"description":"The username of the Nacos API.","type":"string","minLength":1},"password":{"description":"The password of the Nacos API.","type":"string","minLength":1}},"required":["username","password"]},{"properties":{"token":{"type":"string","description":"The token of the Nacos service.","minLength":1}},"required":["token"]},{"properties":{"access_key":{"description":"The access key of the Nacos API.","type":"string","minLength":1},"secret_key":{"description":"The secret key of the Nacos API.","type":"string","minLength":1}},"required":["access_key","secret_key"]}]}}}}}]}]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The service registry model.","allOf":[{"type":"object","required":["name","type"],"allOf":[{"type":"object","properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"health_check":{"type":"object","properties":{"probe_interval":{"default":15,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking service registry (in seconds)."},"probe_timeout":{"default":5,"minimum":1,"type":"integer","format":"int64","description":"The timeout for checking service registry (in seconds)."}}}}},{"oneOf":[{"type":"object","required":["type","kubernetes_config"],"properties":{"type":{"type":"string","enum":["kubernetes"],"description":"The kubernetes service type."},"kubernetes_config":{"type":"object","properties":{"service":{"description":"The IP address of the Kubernetes API server.","type":"object","required":["schema","host","port"],"properties":{"schema":{"type":"string","enum":["http","https"]},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"string","minLength":1,"example":"6443"}}},"namespace_selector":{"description":"The namespace selector to filter target namespaces.","type":"object","nullable":true,"properties":{"equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"not_equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1},"not_match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1}},"oneOf":[{"required":["equal"]},{"required":["not_equal"]},{"required":["match"]},{"required":["not_match"]}]},"label_selector":{"description":"The label selector to filter target endpoints.","type":"string"},"client":{"description":"The client name.","oneOf":[{"properties":{"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","pattern":"^[^\\:*?\"<>|]*$"}},"required":["token_file"]},{"properties":{"token":{"description":"The token of the Kubernetes service account.","type":"string","pattern":"^[A-Za-z0-9+\\/._=-]+$"}},"required":["token"]}]}}}}},{"type":"object","required":["type","nacos_config"],"properties":{"type":{"type":"string","enum":["nacos"],"description":"The Nacos service type."},"nacos_config":{"type":"object","required":["hosts"],"properties":{"hosts":{"description":"The address of the Nacos API server.","type":"array","minItems":1,"items":{"type":"string","format":"url"}},"prefix":{"description":"The prefix of the Nacos API.","type":"string","default":"/nacos/v1"},"default_weight":{"type":"integer","description":"The default weight of the endpoints.","minimum":1,"maximum":100,"example":100,"default":100},"fetch_interval":{"type":"integer","description":"The interval for fetching endpoints (in seconds).","example":30,"default":10},"timeout":{"type":"object","description":"The timeout for connecting, sending and reading (in seconds).","properties":{"connect":{"type":"integer","example":2,"default":2},"send":{"type":"integer","example":2,"default":2},"read":{"type":"integer","example":5,"default":5}}},"auth":{"oneOf":[{"properties":{"username":{"description":"The username of the Nacos API.","type":"string","minLength":1},"password":{"description":"The password of the Nacos API.","type":"string","minLength":1}},"required":["username","password"]},{"properties":{"token":{"type":"string","description":"The token of the Nacos service.","minLength":1}},"required":["token"]},{"properties":{"access_key":{"description":"The access key of the Nacos API.","type":"string","minLength":1},"secret_key":{"description":"The secret key of the Nacos API.","type":"string","minLength":1}},"required":["access_key","secret_key"]}]}}}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"status":{"type":"string","enum":["healthy","lost_connection","connecting"],"default":"connecting","description":"The status of the service registry."},"last_connect_time":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/instance_token":{"post":{"tags":["Gateway Group","Gateway Instance"],"summary":"Create a token for all gateway instances in a gateway group.","operationId":"createGatewayInstanceToken","description":"IAM Action: `gateway:CreateGatewayInstance`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"only_token","description":"The response only contains a token string but not an encoded JSON Web Token (JWT).","in":"query","schema":{"type":"boolean"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"The token.","type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"token_plain_text":{"type":"string","description":"The token in plain text."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}":{"get":{"tags":["Service Registry","Gateway Group"],"summary":"Get a service registry connection on a gateway group.","operationId":"getServiceRegistry","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"description":"The service registry model.","allOf":[{"type":"object","required":["name","type"],"allOf":[{"type":"object","properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"health_check":{"type":"object","properties":{"probe_interval":{"default":15,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking service registry (in seconds)."},"probe_timeout":{"default":5,"minimum":1,"type":"integer","format":"int64","description":"The timeout for checking service registry (in seconds)."}}}}},{"oneOf":[{"type":"object","required":["type","kubernetes_config"],"properties":{"type":{"type":"string","enum":["kubernetes"],"description":"The kubernetes service type."},"kubernetes_config":{"type":"object","properties":{"service":{"description":"The IP address of the Kubernetes API server.","type":"object","required":["schema","host","port"],"properties":{"schema":{"type":"string","enum":["http","https"]},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"string","minLength":1,"example":"6443"}}},"namespace_selector":{"description":"The namespace selector to filter target namespaces.","type":"object","nullable":true,"properties":{"equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"not_equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1},"not_match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1}},"oneOf":[{"required":["equal"]},{"required":["not_equal"]},{"required":["match"]},{"required":["not_match"]}]},"label_selector":{"description":"The label selector to filter target endpoints.","type":"string"},"client":{"description":"The client name.","oneOf":[{"properties":{"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","pattern":"^[^\\:*?\"<>|]*$"}},"required":["token_file"]},{"properties":{"token":{"description":"The token of the Kubernetes service account.","type":"string","pattern":"^[A-Za-z0-9+\\/._=-]+$"}},"required":["token"]}]}}}}},{"type":"object","required":["type","nacos_config"],"properties":{"type":{"type":"string","enum":["nacos"],"description":"The Nacos service type."},"nacos_config":{"type":"object","required":["hosts"],"properties":{"hosts":{"description":"The address of the Nacos API server.","type":"array","minItems":1,"items":{"type":"string","format":"url"}},"prefix":{"description":"The prefix of the Nacos API.","type":"string","default":"/nacos/v1"},"default_weight":{"type":"integer","description":"The default weight of the endpoints.","minimum":1,"maximum":100,"example":100,"default":100},"fetch_interval":{"type":"integer","description":"The interval for fetching endpoints (in seconds).","example":30,"default":10},"timeout":{"type":"object","description":"The timeout for connecting, sending and reading (in seconds).","properties":{"connect":{"type":"integer","example":2,"default":2},"send":{"type":"integer","example":2,"default":2},"read":{"type":"integer","example":5,"default":5}}},"auth":{"oneOf":[{"properties":{"username":{"description":"The username of the Nacos API.","type":"string","minLength":1},"password":{"description":"The password of the Nacos API.","type":"string","minLength":1}},"required":["username","password"]},{"properties":{"token":{"type":"string","description":"The token of the Nacos service.","minLength":1}},"required":["token"]},{"properties":{"access_key":{"description":"The access key of the Nacos API.","type":"string","minLength":1},"secret_key":{"description":"The secret key of the Nacos API.","type":"string","minLength":1}},"required":["access_key","secret_key"]}]}}}}}]}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"status":{"type":"string","enum":["healthy","lost_connection","connecting"],"default":"connecting","description":"The status of the service registry."},"last_connect_time":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Service Registry","Gateway Group"],"summary":"Update a service registry connection on a gateway group.","operationId":"putServiceRegistry","description":"IAM Action: `gateway:UpdateServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name","type"],"allOf":[{"type":"object","properties":{"name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"description":{"type":"string"},"health_check":{"type":"object","properties":{"probe_interval":{"default":15,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking service registry (in seconds)."},"probe_timeout":{"default":5,"minimum":1,"type":"integer","format":"int64","description":"The timeout for checking service registry (in seconds)."}}}}},{"oneOf":[{"type":"object","required":["type","kubernetes_config"],"properties":{"type":{"type":"string","enum":["kubernetes"],"description":"The kubernetes service type."},"kubernetes_config":{"type":"object","properties":{"service":{"description":"The IP address of the Kubernetes API server.","type":"object","required":["schema","host","port"],"properties":{"schema":{"type":"string","enum":["http","https"]},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"string","minLength":1,"example":"6443"}}},"namespace_selector":{"description":"The namespace selector to filter target namespaces.","type":"object","nullable":true,"properties":{"equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"not_equal":{"type":"string","pattern":"^[a-z0-9]([-a-z0-9_.]*[a-z0-9])?$"},"match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1},"not_match":{"type":"array","items":{"type":"string","pattern":"^[\\x21-\\x7e]*$"},"minItems":1}},"oneOf":[{"required":["equal"]},{"required":["not_equal"]},{"required":["match"]},{"required":["not_match"]}]},"label_selector":{"description":"The label selector to filter target endpoints.","type":"string"},"client":{"description":"The client name.","oneOf":[{"properties":{"token_file":{"description":"The path to the token file of the Kubernetes service account.","type":"string","pattern":"^[^\\:*?\"<>|]*$"}},"required":["token_file"]},{"properties":{"token":{"description":"The token of the Kubernetes service account.","type":"string","pattern":"^[A-Za-z0-9+\\/._=-]+$"}},"required":["token"]}]}}}}},{"type":"object","required":["type","nacos_config"],"properties":{"type":{"type":"string","enum":["nacos"],"description":"The Nacos service type."},"nacos_config":{"type":"object","required":["hosts"],"properties":{"hosts":{"description":"The address of the Nacos API server.","type":"array","minItems":1,"items":{"type":"string","format":"url"}},"prefix":{"description":"The prefix of the Nacos API.","type":"string","default":"/nacos/v1"},"default_weight":{"type":"integer","description":"The default weight of the endpoints.","minimum":1,"maximum":100,"example":100,"default":100},"fetch_interval":{"type":"integer","description":"The interval for fetching endpoints (in seconds).","example":30,"default":10},"timeout":{"type":"object","description":"The timeout for connecting, sending and reading (in seconds).","properties":{"connect":{"type":"integer","example":2,"default":2},"send":{"type":"integer","example":2,"default":2},"read":{"type":"integer","example":5,"default":5}}},"auth":{"oneOf":[{"properties":{"username":{"description":"The username of the Nacos API.","type":"string","minLength":1},"password":{"description":"The password of the Nacos API.","type":"string","minLength":1}},"required":["username","password"]},{"properties":{"token":{"type":"string","description":"The token of the Nacos service.","minLength":1}},"required":["token"]},{"properties":{"access_key":{"description":"The access key of the Nacos API.","type":"string","minLength":1},"secret_key":{"description":"The secret key of the Nacos API.","type":"string","minLength":1}},"required":["access_key","secret_key"]}]}}}}}]}]}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Service Registry","Gateway Group"],"summary":"Delete a service registry connection on a gateway group.","operationId":"deleteServiceRegistry","description":"IAM Action: `gateway:DisconnectServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/connected_services":{"get":{"tags":["Service Registry","Gateway Group","Published Service"],"summary":"List all published services connected to a service registry.","operationId":"listServiceRegistryConnectedServices","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at","publish_time","name"]}},{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of service versions.","items":{"allOf":[{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"unhealthy_nodes_count":{"type":"integer"},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/kubernetes/internal_services":{"get":{"tags":["Service Registry","Kubernetes","Gateway Group"],"summary":"List all internal services in a Kubernetes service registry.","operationId":"listKubernetesInternalServices","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","properties":{"type":{"type":"string","enum":["kubernetes"],"description":"The service type."},"internal_services":{"type":"object","additionalProperties":{"type":"array","items":{"type":"string","description":"An array of internal service names."}},"description":"A map of internal services. The Key is the name of namespace and value is the array of internal service names.","example":{"default":["service1","service2"],"kube-system":["kube-dns"]}}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/nacos/namespaces":{"get":{"tags":["Service Registry","Nacos","Gateway Group"],"summary":"List all namespaces in a Nacos service registry.","operationId":"listNacosNamespaces","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of Nacos namespaces.","items":{"type":"object","properties":{"namespace":{"type":"string","description":"The Nacos namespace ID."},"namespace_show_name":{"type":"string","description":"The Nacos namespace name."}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/nacos/namespaces/{nacos_namespace}/groups":{"get":{"tags":["Service Registry","Nacos","Gateway Group"],"summary":"List all groups in a Nacos namespace.","operationId":"listNacosGroups","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"nacos_namespace","in":"path","required":true,"example":"public","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of Nacos groups.","items":{"type":"string"}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/nacos/namespaces/{nacos_namespace}/groups/{nacos_group}/services":{"get":{"tags":["Service Registry","Nacos","Gateway Group"],"summary":"List all internal services in a Nacos group.","operationId":"listNacosInternalServices","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"nacos_namespace","in":"path","required":true,"example":"public","schema":{"minimum":1,"type":"string"}},{"name":"nacos_group","in":"path","required":true,"example":"DEFAULT_GROUP","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of Nacos services.","items":{"type":"string"}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/nacos/namespaces/{nacos_namespace}/groups/{nacos_group}/services/{nacos_service}/instances_metadata":{"get":{"tags":["Service Registry","Nacos","Gateway Group"],"summary":"Get all instance metadata of a Nacos services registry","operationId":"getNacosInstancesMetadata","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"nacos_namespace","in":"path","required":true,"example":"public","schema":{"minimum":1,"type":"string"}},{"name":"nacos_group","in":"path","required":true,"example":"DEFAULT_GROUP","schema":{"minimum":1,"type":"string"}},{"name":"nacos_service","in":"path","required":true,"example":"api7ee3-keycloak","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"value":{"type":"object","description":"An object of Nacos instance metadata.","additionalProperties":{"type":"array","items":{"type":"string"}},"example":{"idc":["beijing","shanghai"]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/health_check_history":{"get":{"tags":["Service Registry","Gateway Group"],"summary":"Get health check history of a service registry connection on a gateway group.","operationId":"getServiceRegistryHealthCheckHistory","description":"IAM Action: `gateway:GetServiceRegistry`, Resource: `arn:api7:gateway:gatewaygroup/%s`","parameters":[{"name":"service_registry_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"gateway_group_id","in":"path","required":true,"example":"86fb9981-d9d2-4555-9df8-91ae92129335","schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"connect_time","enum":["connect_time"]}},{"name":"status","in":"query","schema":{"type":"array","items":{"type":"string","enum":["healthy","lost_connection","connecting"]}}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of health check results of the service registry.","items":{"allOf":[{"type":"object","properties":{"instance_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_registry_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"hostname":{"type":"string"},"status":{"type":"string","enum":["healthy","lost_connection","connecting"]},"connect_time":{"description":"The object timestamp.","type":"integer","minimum":0}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/service_versions/{service_version_id}/oas":{"get":{"tags":["Service Template"],"summary":"Get the OpenAPI Specification of a service version.","operationId":"getServiceVersionOAS","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_version_id","description":"The unique identifier of the service version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"raw_openapi":{"type":"string","description":"The OpenAPI specification of the service."},"api_count":{"type":"integer","description":"The number of APIs in the service."},"api_desc":{"type":"string","description":"The description of the OAS."}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/service_versions/{service_version_id}":{"get":{"tags":["Service Template"],"summary":"Get a service version.","operationId":"getServiceVersion","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_version_id","description":"The unique identifier of the service version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/service_versions/{service_version_id}/routes":{"get":{"tags":["Service Template"],"summary":"Get all routes in a service version.","operationId":"listRoutesInServiceVersion","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_version_id","description":"The unique identifier of the service version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of route versions.","items":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/service_versions/{service_version_id}/routes/{route_version_id}":{"get":{"tags":["Service Template"],"summary":"Get a route in a service version.","operationId":"getRouteInServiceVersion","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_version_id","description":"The unique identifier of the service version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"route_version_id","description":"The unique identifier of the route version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/service_versions/{service_version_id}/stream_routes":{"get":{"tags":["Service Template"],"summary":"Get all stream routes in a service versions.","operationId":"listStreamRoutesInServiceVersion","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_version_id","description":"The unique identifier of the service version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of route versions.","items":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"stream_route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/service_versions/{service_version_id}/stream_routes/{stream_route_version_id}":{"get":{"tags":["Service Template"],"summary":"Get a stream route in a service version.","operationId":"getStreamRouteInServiceVersion","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_version_id","description":"The unique identifier of the service version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"stream_route_version_id","description":"The unique identifier of the stream route version.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"remote_addr":{"type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},"server_addr":{"anyOf":[{"title":"IPAddress","type":"string","anyOf":[{"title":"IPv4","format":"ipv4","type":"string","example":"127.0.0.1"},{"title":"IPv4/CIDR","type":"string","pattern":"^([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/([12]?[0-9]|3[0-2])$"},{"title":"IPv6","type":"string","format":"ipv6"},{"title":"IPv6/CIDR","type":"string","pattern":"^([a-fA-F0-9]{0,4}:){1,8}(:[a-fA-F0-9]{0,4}){0,8}([a-fA-F0-9]{0,4})?/[0-9]{1,3}$"}]},{"type":"string","title":"Domain"}],"example":"mysql"},"server_port":{"type":"integer","maximum":65535,"example":3306}}},{"type":"object","properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"stream_route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_version_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/services/publish":{"post":{"tags":["Service Template"],"summary":"Publish a service template to a gateway group.","operationId":"publishServiceTemplate","description":"IAM Action: `gateway:PublishServices`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","requestBody":{"content":{"application/json":{"schema":{"type":"object","minProperties":1,"properties":{"create_new_version":{"type":"boolean","description":"Whether to create a new service version for the updated service."},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"services":{"type":"array","minItems":1,"items":{"type":"object","required":["service_id","version"],"properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"service_version_id":{"description":"It is required when `create_new_version` is set to `false`.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/services/conflict_check":{"post":{"tags":["Published Service"],"summary":"Check service conflict.","requestBody":{"content":{"application/json":{"schema":{"type":"object","minProperties":1,"properties":{"create_new_version":{"type":"boolean","description":"Whether to create a new service version for the updated service."},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"services":{"type":"array","minItems":1,"items":{"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"hosts":{"type":"array","description":"The hosts for the service to accept incoming requests.","uniqueItems":true,"minItems":1,"maxItems":32,"items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"path_prefix":{"maxLength":4096,"minLength":1,"pattern":"^/","type":"string","description":"The listening path prefix of the service."}}},{"type":"object","required":["service_id"],"properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"service_version_id":{"description":"It is required when `create_new_version` is set to `false`.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"status":{"default":1,"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"routes":{"type":"array","items":{"description":"The route with management fields.","allOf":[{"description":"The route description.","type":"object","required":["name","paths"],"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"methods":{"description":"The allowed HTTP methods to access the route. If empty, all HTTP methods are allowed.","type":"array","uniqueItems":true,"minItems":1,"maxItems":9,"items":{"type":"string","description":"The API (HTTP) method.","enum":["GET","POST","PUT","DELETE","PATCH","HEAD","OPTIONS","TRACE"]}},"vars":{"description":"Matches based on the specified variables consistent with variables in Nginx. Takes the form [[var, operator, val], [var, operator, val], ...]]. Note that this is case sensitive when matching a cookie name. See https://github.com/api7/lua-resty-expr for more details.","type":"array","items":{}},"paths":{"maxItems":64,"minItems":1,"type":"array","description":"The URI paths that can be matched to the API.","items":{"type":"string","pattern":"^/","description":"The URL path (after the service path_prefix) that the route will listen.","minLength":1,"maxLength":4096}},"priority":{"type":"integer","default":0,"description":"If different Routes matches to the same uri, then the Route is matched based on its priority. A higher value corresponds to higher priority."},"enable_websocket":{"type":"boolean","description":"Define whether to enable Websocket for the route."}}},{"type":"object","properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}}]}}}}]}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"duplicate":{"type":"array","description":"An array of duplicated services and routes.","items":{"type":"array","description":"An array of conflicting services and routes.","items":{"type":"object","properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_name":{"type":"string","description":"The service name."},"route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"route_name":{"type":"string","description":"The route name."},"url":{"type":"string"}}}}},"overlapping":{"type":"array","description":"An array of overlapping services and routes.","items":{"type":"array","description":"An array of conflicting services and routes.","items":{"type":"object","properties":{"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_name":{"type":"string","description":"The service name."},"route_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"route_name":{"type":"string","description":"The route name."},"url":{"type":"string"}}}}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/services/{service_template_id}/published_services":{"get":{"tags":["Service Template"],"summary":"List all published version of a service template on multiple gateway groups.","operationId":"listServiceTemplatePublishedVersions","description":"IAM Action: `gateway:GetPublishedService`, Resource: `arn:api7:gateway:gatewaygroup/%s/publishedservice/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of published services.","items":{"allOf":[{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]},{"type":"object","properties":{"gateway_group_name":{"description":"The object name.","type":"string","minLength":1,"maxLength":100},"gateway_group_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"unhealthy_nodes_count":{"type":"integer"},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/services/{service_template_id}/versions/{version}":{"get":{"tags":["Service Template"],"summary":"Get the service version name.","operationId":"getServiceVersionByVersionName","description":"IAM Action: `gateway:GetServiceTemplate`, Resource: `arn:api7:gateway:servicetemplate/%s`","parameters":[{"name":"service_template_id","description":"The unique identifier of the service template.","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},{"name":"version","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"type":"object","minProperties":1,"allOf":[{"type":"object","properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","enum":["http","stream"],"default":"http"}}}]},{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"service_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"version":{"type":"string"},"created_at":{"description":"The time (first release) when a service version is created.","type":"integer","minimum":0}}}]}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/plugins":{"get":{"tags":["Plugin"],"summary":"Get a plugin detail.","operationId":"getPlugin","parameters":[{"name":"subsystem","in":"query","schema":{"type":"string","default":"http","enum":["http","stream"],"example":"stream"},"description":"Filter the plugins list"},{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"The plugin response.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"array","items":{"type":"object","properties":{"plugin_name":{"description":"The plugin name","type":"string","minLength":1,"maxLength":100},"type":{"type":"string","description":"The plugin type."},"is_custom":{"type":"boolean","description":"Whether the plugin is custom plugin or not"}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/plugins/catalogs":{"get":{"tags":["Plugin"],"summary":"List all plugin catalogs.","operationId":"listPluginCatalogs","responses":{"200":{"description":"The plugin catalog response.","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"array","items":{"type":"string"}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/plugins/{plugin_name}/usage":{"get":{"tags":["Plugin"],"summary":"Get the usage of a plugin.","operationId":"getPluginUsage","parameters":[{"name":"plugin_name","in":"path","schema":{"type":"string","minLength":1,"maxLength":64},"required":true}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"published_service":{"type":"object","properties":{"total":{"type":"integer","example":12},"list":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"id":{"type":"string"},"gateway_group_id":{"type":"string"},"gateway_group_name":{"type":"string"}}}}}},"consumer":{"type":"object","properties":{"total":{"type":"integer","example":12},"list":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"id":{"type":"string"},"gateway_group_id":{"type":"string"},"gateway_group_name":{"type":"string"}}}}}},"global_rule":{"type":"object","properties":{"total":{"type":"integer","example":12},"list":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"id":{"type":"string"},"gateway_group_id":{"type":"string"},"gateway_group_name":{"type":"string"}}}}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/openapi/request_body_schema":{"get":{"tags":["Schema"],"summary":"Get OpenAPI schema","operationId":"getOpenAPISchema","parameters":[{"name":"method","in":"query","required":true,"schema":{"minimum":1,"type":"string","enum":["POST","PUT"]}},{"name":"path","in":"query","required":true,"example":"GET","schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object"}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/schema/core":{"get":{"tags":["Schema"],"summary":"Get core APIs schema","operationId":"getCoreAPISchema","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"service":{"type":"object"},"route":{"type":"object"},"consumer":{"type":"object"},"global_rule":{"type":"object"},"ssl":{"type":"object"},"secret":{"type":"object"},"plugin_metadata":{"type":"object"}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/labels/{resource_type}":{"get":{"tags":["Label"],"summary":"Get all labels of a resource type.","operationId":"listLabels","parameters":[{"name":"resource_type","in":"path","required":true,"schema":{"type":"string","enum":["gateway_group","consumer","consumer_credential","ssl","service","route","stream_route","role","permission_policy","published_service","secret","contact_point","alert_policy","certificate","api_product","sni"]}},{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":{"type":"array","items":{"type":"string"}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/system_settings":{"put":{"tags":["System Settings"],"summary":"Update deployment settings.","operationId":"putDeploymentSettings","description":"IAM Action: `gateway:UpdateDeploymentSetting`, Resource: `arn:api7:gateway:gatewaysetting/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"control_plane_address":{"maxItems":32,"minItems":0,"uniqueItems":true,"type":"array","items":{"type":"string","minLength":1,"pattern":"[^\\/]$","format":"url_scheme_port","description":"The IP address of the control plane."}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"control_plane_address":{"maxItems":32,"minItems":0,"uniqueItems":true,"type":"array","items":{"type":"string","minLength":1,"pattern":"[^\\/]$","format":"url_scheme_port","description":"The IP address of the control plane."}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["System Settings"],"summary":"Get deployment settings.","operationId":"getDeploymentSettings","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"control_plane_address":{"maxItems":32,"minItems":0,"uniqueItems":true,"type":"array","items":{"type":"string","minLength":1,"pattern":"[^\\/]$","format":"url_scheme_port","description":"The IP address of the control plane."}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/system_settings/scim":{"put":{"tags":["System Settings"],"summary":"Update SCIM settings.","operationId":"putSCIMSettings","description":"IAM Action: `iam:UpdateSCIMProvisioning`, Resource: `arn:api7:iam:organization/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"enable_scim":{"type":"boolean","description":"Enable SCIM endpoint."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"enable_scim":{"type":"boolean","description":"Enable SCIM endpoint."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["System Settings"],"summary":"Get SCIM settings.","operationId":"getSCIMSettings","description":"IAM Action: `iam:GetSCIMProvisioning`, Resource: `arn:api7:iam:organization/*`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"enable_scim":{"type":"boolean","description":"Enable SCIM endpoint."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/system_settings/scim/token":{"put":{"tags":["System Settings"],"summary":"Generate SCIM Token.","operationId":"generateSCIMToken","description":"IAM Action: `iam:UpdateSCIMProvisioning`, Resource: `arn:api7:iam:organization/*`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"string"}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/system_settings/smtp_server":{"put":{"tags":["System Settings"],"summary":"Update SMTP server settings.","description":"IAM Action: `iam:UpdateSMTPServer`, Resource: `arn:api7:iam:organization/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"enable":{"type":"boolean","description":"Enable SMTP Server."},"address":{"type":"string","format":"host_port","description":"The SMTP server address."},"authentication_type":{"type":"string","description":"The authentication type of the SMTP server.","enum":["TLS","STARTTLS"]},"ssl_verify":{"type":"boolean","description":"Whether to validate server-side SSL."},"username":{"type":"string"},"password":{"type":"string"},"from_name":{"description":"Sender's name.","type":"string","pattern":"^\\s*(\"(?:[^\"\\\\]|\\\\.)*\"|([^<>@]+))?\\s*$"},"from_address":{"type":"string","format":"email","description":"Sender's email address."}},"required":["enable","address","ssl_verify","username","password","from_name","from_address"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"enable":{"type":"boolean","description":"Enable SMTP Server."},"address":{"type":"string","format":"host_port","description":"The SMTP server address."},"authentication_type":{"type":"string","description":"The authentication type of the SMTP server.","enum":["TLS","STARTTLS"]},"ssl_verify":{"type":"boolean","description":"Whether to validate server-side SSL."},"username":{"type":"string"},"password":{"type":"string"},"from_name":{"description":"Sender's name.","type":"string","pattern":"^\\s*(\"(?:[^\"\\\\]|\\\\.)*\"|([^<>@]+))?\\s*$"},"from_address":{"type":"string","format":"email","description":"Sender's email address."}},"required":["enable","address","ssl_verify","username","password","from_name","from_address"]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["System Settings"],"summary":"Get SMTP server settings.","description":"IAM Action: `iam:GetSMTPServer`, Resource: `arn:api7:iam:organization/*`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"enable":{"type":"boolean","description":"Enable SMTP Server."},"address":{"type":"string","format":"host_port","description":"The SMTP server address."},"authentication_type":{"type":"string","description":"The authentication type of the SMTP server.","enum":["TLS","STARTTLS"]},"ssl_verify":{"type":"boolean","description":"Whether to validate server-side SSL."},"username":{"type":"string"},"password":{"type":"string"},"from_name":{"description":"Sender's name.","type":"string","pattern":"^\\s*(\"(?:[^\"\\\\]|\\\\.)*\"|([^<>@]+))?\\s*$"},"from_address":{"type":"string","format":"email","description":"Sender's email address."}},"required":["enable","address","ssl_verify","username","password","from_name","from_address"]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/system_settings/smtp_server_status":{"get":{"tags":["System Settings"],"summary":"Get SMTP server settings status.","description":"Get SMTP server settings status.","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"enable":{"type":"boolean","description":"Enable SMTP Server."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/system_infos":{"get":{"tags":["System Infos"],"summary":"Get all system infos.","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"deployment_id":{"type":"string","description":"A unique identifier that is automatically generated with each deployment of API7EE."},"deployed_at":{"description":"The API7 EE dashboard deployed at.","type":"integer","minimum":0},"free_trial_expired_at":{"description":"Free trial expiry time.","type":"integer","minimum":0}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/portal/system_settings/public_access":{"put":{"tags":["Developer Login Settings"],"summary":"Update developer portal public access.","operationId":"putDeveloperPortalPublicAccess","description":"IAM Action: `portal:UpdateDeveloperPortalPublicAccess`, Resource: `arn:api7:portal:loginsetting/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"portal_public_access":{"type":"boolean","description":"Whether to allow public access to the developer portal."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"portal_public_access":{"type":"boolean","description":"Whether to allow public access to the developer portal."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Developer Login Settings"],"summary":"Get developer portal public access.","operationId":"getDeveloperPortalPublicAccess","description":"IAM Action: `portal:GetDeveloperPortalPublicAccess`, Resource: `arn:api7:portal:loginsetting/*`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"portal_public_access":{"type":"boolean","description":"Whether to allow public access to the developer portal."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/portal/login_options":{"get":{"tags":["Developer Login Settings"],"summary":"List all developer login options.","operationId":"listDeveloperLoginOptions","description":"IAM Action: `portal:GetDeveloperLoginOption`, Resource: `arn:api7:portal:loginsetting/*`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"in":"query","name":"name","schema":{"type":"string"},"description":"Name is the name of the resource."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","description":"Built-in specific configuration","properties":{"enable_self_registration":{"type":"boolean","description":"Whether to enable self registration."},"registration_auto_approval":{"type":"boolean","description":"Whether to auto approve new registrations."},"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["Developer Login Settings"],"summary":"Create a developer login option.","operationId":"createDeveloperLoginOption","description":"IAM Action: `portal:CreateDeveloperLoginOption`, Resource: `arn:api7:portal:loginsetting/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","minLength":1,"maxLength":256},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","client_secret","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The logout URL of the OIDC provider.","example":"http://api7ee3-keycloak/realms/master/logout"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The SP root URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider.","default":true},"logout_idp_session":{"type":"boolean","description":"Whether redirect to IDP for logout or not.","default":false},"private_key":{"type":"string","description":"The private key of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","description":"Built-in specific configuration","properties":{"enable_self_registration":{"type":"boolean","description":"Whether to enable self registration."},"registration_auto_approval":{"type":"boolean","description":"Whether to auto approve new registrations."},"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"Array of login options","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of boundary mappings defining operations and conditions under which boundary are applied."}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/portal/login_options/{login_option_id}":{"get":{"tags":["Developer Login Settings"],"summary":"Get a developer login option.","operationId":"getDeveloperLoginOption","description":"IAM Action: `portal:GetDeveloperLoginOption`, Resource: `arn:api7:portal:loginsetting/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","description":"Built-in specific configuration","properties":{"enable_self_registration":{"type":"boolean","description":"Whether to enable self registration."},"registration_auto_approval":{"type":"boolean","description":"Whether to auto approve new registrations."},"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Developer Login Settings"],"summary":"Update a developer login option.","operationId":"putDeveloperLoginOption","description":"IAM Action: `portal:UpdateDeveloperLoginOption`, Resource: `arn:api7:portal:loginsetting/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","minLength":1,"maxLength":256},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","client_secret","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The logout URL of the OIDC provider.","example":"http://api7ee3-keycloak/realms/master/logout"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The SP root URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider.","default":true},"logout_idp_session":{"type":"boolean","description":"Whether redirect to IDP for logout or not.","default":false},"private_key":{"type":"string","description":"The private key of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","description":"Built-in specific configuration","properties":{"enable_self_registration":{"type":"boolean","description":"Whether to enable self registration."},"registration_auto_approval":{"type":"boolean","description":"Whether to auto approve new registrations."},"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","description":"Built-in specific configuration","properties":{"enable_self_registration":{"type":"boolean","description":"Whether to enable self registration."},"registration_auto_approval":{"type":"boolean","description":"Whether to auto approve new registrations."},"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["Developer Login Settings"],"summary":"Patch a developer login option.","operationId":"patchDeveloperLoginOption","description":"IAM Action: `portal:UpdateDeveloperLoginOption`, Resource: `arn:api7:portal:loginsetting/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","description":"Built-in specific configuration","properties":{"enable_self_registration":{"type":"boolean","description":"Whether to enable self registration."},"registration_auto_approval":{"type":"boolean","description":"Whether to auto approve new registrations."},"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Developer Login Settings"],"summary":"Delete a developer login option.","operationId":"deleteDeveloperLoginOption","description":"IAM Action: `portal:DeleteDeveloperLoginOption`, Resource: `arn:api7:portal:loginsetting/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/portal/system_settings/scim":{"put":{"tags":["Developer Login Settings"],"summary":"Update Developer SCIM settings.","operationId":"putDeveloperSCIMSettings","description":"IAM Action: `portal:UpdateDeveloperSCIMProvisioning`, Resource: `arn:api7:portal:loginsetting/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"enable_scim":{"type":"boolean","description":"Enable SCIM endpoint."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"enable_scim":{"type":"boolean","description":"Enable SCIM endpoint."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Developer Login Settings"],"summary":"Get Developer SCIM settings.","operationId":"getDeveloperSCIMSettings","description":"IAM Action: `portal:GetDeveloperSCIMProvisioning`, Resource: `arn:api7:portal:loginsetting/*`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":false,"properties":{"enable_scim":{"type":"boolean","description":"Enable SCIM endpoint."}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/portal/system_settings/scim/token":{"put":{"tags":["Developer Login Settings"],"summary":"Generate Developer SCIM Token.","operationId":"generateDeveloperSCIMToken","description":"IAM Action: `portal:UpdateDeveloperSCIMProvisioning`, Resource: `arn:api7:portal:loginsetting/*`","responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"string"}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/login_options/{login_option_id}":{"get":{"tags":["System Settings","Login Option"],"summary":"Get a login option.","operationId":"getLoginOption","description":"IAM Action: `iam:GetLoginOption`, Resource: `arn:api7:iam:organization/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of boundary mappings defining operations and conditions under which boundary are applied."}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["System Settings","Login Option"],"summary":"Update a login option.","operationId":"putLoginOption","description":"IAM Action: `iam:UpdateLoginOption`, Resource: `arn:api7:iam:organization/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","minLength":1,"maxLength":256},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","client_secret","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The logout URL of the OIDC provider.","example":"http://api7ee3-keycloak/realms/master/logout"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The SP root URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider.","default":true},"logout_idp_session":{"type":"boolean","description":"Whether redirect to IDP for logout or not.","default":false},"private_key":{"type":"string","description":"The private key of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of permission boundary mappings defining operations and conditions under which permission boundary are applied."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of boundary mappings defining operations and conditions under which boundary are applied."}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"patch":{"tags":["System Settings","Login Option"],"summary":"Patch a login option.","operationId":"patchLoginOption","description":"IAM Action: `iam:UpdateLoginOption`, Resource: `arn:api7:iam:organization/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","description":"A JSON Patch payload as defined by RFC 6902, see https://jsonpatch.com for more information","items":{"type":"object","oneOf":[{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["add","replace"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to modify or add, see https://jsonpatch.com/#json-pointer for more information"},"value":{"description":"The value to add or replace, can be any type"}},"required":["op","path","value"]},{"properties":{"op":{"type":"string","description":"The operation to be performed","enum":["remove"]},"path":{"type":"string","description":"A JSON Pointer path to the value you wish to remove"}},"required":["op","path"]}]}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of boundary mappings defining operations and conditions under which boundary are applied."}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["System Settings","Login Option"],"summary":"Delete a login option.","operationId":"deleteLoginOption","description":"IAM Action: `iam:DeleteLoginOption`, Resource: `arn:api7:iam:organization/*`","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/login_options":{"get":{"tags":["System Settings","Login Option"],"summary":"List all login options.","operationId":"listLoginOptions","description":"IAM Action: `iam:GetLoginOption`, Resource: `arn:api7:iam:organization/*`","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"in":"query","name":"name","schema":{"type":"string"},"description":"Name is the name of the resource."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"Array of login options","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of boundary mappings defining operations and conditions under which boundary are applied."}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["System Settings","Login Option"],"summary":"Create a login option.","operationId":"createLoginOption","description":"IAM Action: `iam:CreateLoginOption`, Resource: `arn:api7:iam:organization/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","minLength":1,"maxLength":256},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","client_secret","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The logout URL of the OIDC provider.","example":"http://api7ee3-keycloak/realms/master/logout"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","oneOf":[{"format":"url","title":"url"},{"title":"$env://","type":"string","pattern":"^\\$env://"}],"description":"The SP root URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider.","default":true},"logout_idp_session":{"type":"boolean","description":"Whether redirect to IDP for logout or not.","default":false},"private_key":{"type":"string","description":"The private key of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of permission boundary mappings defining operations and conditions under which permission boundary are applied."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"Array of login options","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"oidc_config":{"type":"object","required":["client_id","issuer","request_scopes","root_url"],"properties":{"client_id":{"type":"string","description":"The client ID of the OIDC provider."},"client_secret":{"type":"string","description":"The client secret of the OIDC provider."},"issuer":{"type":"string","description":"The issuer URL of the OIDC provider."},"request_scopes":{"type":"array","items":{"type":"string"},"description":"The request scopes of the OIDC provider.","example":["openid","email","profile"]},"ssl_verify":{"type":"boolean","description":"Whether to verify the SSL certificate of the OIDC provider.","default":true},"callback_url":{"type":"string","description":"The root URL for the OIDC provider used to generate the callback URL.","example":"http://127.0.0.1:7080"},"logout_url":{"type":"string","description":"The logout URL of the OIDC provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"saml_config":{"type":"object","required":["idp_metadata_url","sp_root_url"],"properties":{"idp_metadata_url":{"type":"string","description":"The IDP metadata URL of the SAML provider."},"sp_root_url":{"type":"string","description":"The SP root URL of the SAML provider."},"sp_acs_url":{"type":"string","description":"The SP ACS URL of the SAML provider."},"sp_slo_url":{"type":"string","description":"The SP SLO URL of the SAML provider."},"sp_metadata_url":{"type":"string","description":"The SP metadata URL of the SAML provider."},"sign_request":{"type":"boolean","description":"Whether to sign the request of the SAML provider."},"certificate":{"type":"string","description":"The certificate of the SAML provider."},"entity_id":{"type":"string","description":"The entity ID of the SAML provider."},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","additionalProperties":{"type":"string"}}}},"ldap_config":{"type":"object","required":["host","port","base_dn","bind_dn","identifier"],"properties":{"host":{"type":"string","description":"The host domain of the LDAP server."},"port":{"type":"string","description":"The port ID of the LDAP server."},"base_dn":{"type":"string","description":"The base DN of the LDAP server."},"bind_dn":{"type":"string","description":"Search user bind DN."},"bind_password":{"type":"string","description":"Search user bind password."},"identifier":{"type":"string","description":"The identifier of the LDAP server. Together with the username, it forms the full DN.","example":"cn"},"attributes":{"type":"object","description":"The attributes used to map the user information to API7 Enterprise.","properties":{"username":{"type":"string"}},"additionalProperties":{"type":"string"}},"timeout":{"type":"integer","description":"Timeout in seconds.","default":10,"minimum":0},"use_ssl":{"type":"boolean","description":"Set it to true if the LDAP server uses an encrypted TLS connection.","default":false},"ssl_verify":{"type":"boolean","description":"Set it to false if you want to skip SSL certificate validation.","default":true},"root_ca_cert":{"type":"string","description":"Set the data of your root CA certificate."},"client_cert":{"type":"string","description":"The client certificate."},"client_key":{"type":"string","description":"The client private key."}}},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}},"role_mapping":{"type":"array","items":{"type":"object","properties":{"role_id":{"type":"string","description":"Unique identifier for the role."},"role_attribute_key":{"type":"string","description":"The key used to identify the role attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"role_attribute_value":{"type":"string","description":"The value expected for the role attribute based on the operation."}},"required":["role_id","role_attribute_key","operation","role_attribute_value"]},"description":"A list of role mappings defining operations and conditions under which roles are applied."},"boundary_mapping":{"type":"array","items":{"type":"object","properties":{"permission_policy_id":{"type":"string","description":"Unique identifier for the boundary permission policy."},"attribute_key":{"type":"string","description":"The key used to identify the boundary permission policy attribute."},"operation":{"type":"string","enum":["exact_match","contains_string","exact_match_in_array","contains_string_in_array"],"description":"The operation to apply on the role attribute. Can be one of exact_match (matches exactly), contains_string (contains the string), exact_match_in_array (an exact match within an array), or contains_string_in_array (a substring match within an array element).\n"},"attribute_value":{"type":"string","description":"The value expected for the boundary permission policy attribute based on the operation."}},"required":["permission_policy_id","attribute_key","operation","attribute_value"]},"description":"A list of boundary mappings defining operations and conditions under which boundary are applied."}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/login_options_for_login":{"get":{"tags":["System Settings","Login Option"],"summary":"List all login options for login.","operationId":"listLoginOptionsForLogin","description":"list login options for login","parameters":[{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"in":"query","name":"name","schema":{"type":"string"},"description":"Name is the name of the resource."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"Array of login options","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"name":{"type":"string"},"logo":{"type":"string","description":"The base64 logo image."},"disable":{"type":"boolean","description":"Whether to disable the login option.","default":false},"provider_type":{"type":"string","enum":["ldap","oidc","saml","built_in"],"description":"The login option type."},"builtin_config":{"type":"object","properties":{"login_with_email":{"type":"boolean","description":"Enable or disable Email login.","default":false}}}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/ldap/{login_option_id}/login":{"post":{"tags":["User"],"summary":"Log in to API7 Enterprise using the username and password.","operationId":"LDAPLogin","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["username","password"],"properties":{"username":{"description":"The username of the user.","type":"string","minLength":1,"maxLength":128},"password":{"description":"The password of the user.","type":"string","minLength":1,"maxLength":128}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/ldap/{login_option_id}/logout":{"post":{"tags":["User"],"summary":"Log out from API7 Enterprise using the username and password.","operationId":"LDAPLogout","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/oidc/{login_option_id}/login":{"get":{"tags":["User"],"summary":"Log in using the OIDC provider.","operationId":"OIDCLogin","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"307":{"description":"Redirect","content":{}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/oidc/{login_option_id}/callback":{"get":{"tags":["User"],"summary":"Log in using the OIDC provider.","operationId":"OIDCCallback","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"state","in":"query","description":"The field of the OIDC protocol.","required":true,"schema":{"type":"string"}},{"name":"code","in":"query","description":"The field of the OIDC protocol.","required":true,"schema":{"type":"string"}}],"responses":{"303":{"description":"Redirect to the home page.","content":{}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/oidc/{login_option_id}/logout":{"get":{"tags":["User"],"summary":"Log out using the OIDC provider.","operationId":"OIDCLogout","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"307":{"description":"Redirect","content":{}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/version":{"get":{"tags":["Common"],"summary":"Get Dashboard Version","operationId":"getDashboardVersion","responses":{"200":{"description":"get dashboard version","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"description":"dashboard version","type":"string"}}}]}}}}}}},"/api/custom_plugins":{"get":{"tags":["Custom Plugin"],"summary":"List all custom plugins.","operationId":"listCustomPlugins","description":"IAM Action: `gateway:GetCustomPlugin`, Resource: `arn:api7:gateway:gatewaysetting/*`","parameters":[{"name":"gateway_group_id","in":"query","required":false,"schema":{"minimum":1,"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"in":"query","name":"name","schema":{"type":"string"},"description":"Name is the name of the resource."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"Array of custom plugins.","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The name of the plugin."},"version":{"type":"string","description":"The version of the plugin."},"source_code":{"type":"string","description":"The source code for the plugin."},"catalog":{"type":"string","description":"The catalog to which the plugin belongs, such as 'Traffic' or 'Observability'."},"description":{"type":"string","description":"A brief description of the plugin."},"documentation_link":{"type":"string","description":"A link to the plugin's documentation.","example":"https://docs.api7.ai/hub/graphql-limit-count"},"author":{"type":"string"},"logo":{"type":"string","description":"An optional logo for the plugin."},"is_obfuscated":{"type":"boolean","description":"Whether it is obfuscated or not"},"gateway_groups":{"type":"array","items":{"type":"string","description":"Gateway Group ID."}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"tags":["Custom Plugin"],"summary":"Create a custom plugin.","operationId":"createCustomPlugin","description":"IAM Action: `gateway:CreateCustomPlugin`, Resource: `arn:api7:gateway:gatewaysetting/*`","requestBody":{"content":{"application/json":{"schema":{"type":"object","oneOf":[{"required":["source_code"]},{"required":["file"]}],"properties":{"source_code":{"type":"string","description":"The source code for the plugin."},"file":{"type":"string","description":"The source code or zip file for the plugin."},"catalog":{"type":"string","description":"The catalog to which the plugin belongs, such as 'Traffic' or 'Observability'."},"description":{"type":"string","description":"A brief description of the plugin."},"documentation_link":{"type":"string","description":"A link to the plugin's documentation.","example":"https://docs.api7.ai/hub/graphql-limit-count"},"author":{"type":"string"},"logo":{"type":"string","description":"An optional logo for the plugin."},"gateway_groups":{"type":"array","description":"The IDs of Gateway Groups that the custom plugin will be deployed.","items":{"type":"string"}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The name of the plugin."},"version":{"type":"string","description":"The version of the plugin."},"source_code":{"type":"string","description":"The source code for the plugin."},"catalog":{"type":"string","description":"The catalog to which the plugin belongs, such as 'Traffic' or 'Observability'."},"description":{"type":"string","description":"A brief description of the plugin."},"documentation_link":{"type":"string","description":"A link to the plugin's documentation.","example":"https://docs.api7.ai/hub/graphql-limit-count"},"author":{"type":"string"},"logo":{"type":"string","description":"An optional logo for the plugin."},"is_obfuscated":{"type":"boolean","description":"Whether it is obfuscated or not"},"gateway_groups":{"type":"array","items":{"type":"string","description":"Gateway Group ID."}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/custom_plugins/{custom_plugin_id}":{"get":{"tags":["Custom Plugin"],"summary":"Get a custom plugin","operationId":"getCustomPlugin","description":"IAM Action: `gateway:GetCustomPlugin`, Resource: `arn:api7:gateway:gatewaysetting/*`","parameters":[{"name":"custom_plugin_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The name of the plugin."},"version":{"type":"string","description":"The version of the plugin."},"source_code":{"type":"string","description":"The source code for the plugin."},"catalog":{"type":"string","description":"The catalog to which the plugin belongs, such as 'Traffic' or 'Observability'."},"description":{"type":"string","description":"A brief description of the plugin."},"documentation_link":{"type":"string","description":"A link to the plugin's documentation.","example":"https://docs.api7.ai/hub/graphql-limit-count"},"author":{"type":"string"},"logo":{"type":"string","description":"An optional logo for the plugin."},"is_obfuscated":{"type":"boolean","description":"Whether it is obfuscated or not"},"gateway_groups":{"type":"array","items":{"type":"string","description":"Gateway Group ID."}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Custom Plugin"],"summary":"Update a custom plugin.","operationId":"putCustomPlugin","description":"IAM Action: `gateway:UpdateCustomPlugin`, Resource: `arn:api7:gateway:gatewaysetting/*`","parameters":[{"name":"custom_plugin_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","oneOf":[{"required":["source_code"]},{"required":["file"]}],"properties":{"source_code":{"type":"string","description":"The source code for the plugin."},"file":{"type":"string","description":"The source code or zip file for the plugin."},"catalog":{"type":"string","description":"The catalog to which the plugin belongs, such as 'Traffic' or 'Observability'."},"description":{"type":"string","description":"A brief description of the plugin."},"documentation_link":{"type":"string","description":"A link to the plugin's documentation.","example":"https://docs.api7.ai/hub/graphql-limit-count"},"author":{"type":"string"},"logo":{"type":"string","description":"An optional logo for the plugin."},"gateway_groups":{"type":"array","description":"The IDs of Gateway Groups that the custom plugin will be deployed.","items":{"type":"string"}}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"name":{"type":"string","description":"The name of the plugin."},"version":{"type":"string","description":"The version of the plugin."},"source_code":{"type":"string","description":"The source code for the plugin."},"catalog":{"type":"string","description":"The catalog to which the plugin belongs, such as 'Traffic' or 'Observability'."},"description":{"type":"string","description":"A brief description of the plugin."},"documentation_link":{"type":"string","description":"A link to the plugin's documentation.","example":"https://docs.api7.ai/hub/graphql-limit-count"},"author":{"type":"string"},"logo":{"type":"string","description":"An optional logo for the plugin."},"is_obfuscated":{"type":"boolean","description":"Whether it is obfuscated or not"},"gateway_groups":{"type":"array","items":{"type":"string","description":"Gateway Group ID."}},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Custom Plugin"],"summary":"Delete a custom plugin.","operationId":"deleteCustomPlugin","description":"IAM Action: `gateway:DeleteCustomPlugin`, Resource: `arn:api7:gateway:gatewaysetting/*`","parameters":[{"name":"custom_plugin_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/custom_plugins/code/parse":{"put":{"tags":["Custom Plugin"],"summary":"Parse custom plugin code.","operationId":"parseCustomPluginCode","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","description":"The source code or zip file for the plugin."}}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","properties":{"name":{"type":"string","description":"The name of the plugin code."},"version":{"type":"string","description":"The version of the plugin code."},"catalog":{"type":"string","description":"The catalog to which the plugin belongs, such as 'Traffic' or 'Observability'."},"description":{"type":"string","description":"A brief description of the plugin."},"documentation_link":{"type":"string","description":"A link to the plugin's documentation.","example":"https://docs.api7.ai/hub/graphql-limit-count"},"author":{"type":"string"},"logo":{"type":"string","description":"An optional logo for the plugin."}}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/saml/{login_option_id}/login":{"get":{"tags":["User"],"summary":"SAML login, will redirect to IDP and callback to SP(dashboard)","operationId":"SAMLLogin","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"redirect_uri","in":"query","description":"Path to be redirected after callback","schema":{"type":"string","minLength":1,"pattern":"^/"}}],"responses":{"302":{"description":"Redirect to IDP.","content":{}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/saml/{login_option_id}/logout":{"get":{"tags":["User"],"summary":"SAML Logout, will redirect to IDP and callback to SP(dashboard)","operationId":"SAMLLogout","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"redirect_uri","in":"query","description":"Path to be redirected after callback","schema":{"type":"string","minLength":1,"pattern":"^/"}}],"responses":{"302":{"description":"Redirect to IDP.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/saml/{login_option_id}/acs":{"post":{"operationId":"SAMLACSCallback","tags":["User"],"summary":"SAML ACS/SLO callback, from IDP callback to SP(dashboard)","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","required":["SAMLResponse"],"properties":{"SAMLResponse":{"type":"string","description":"Base64 encoded SAML response"},"RelayState":{"type":"string","description":"State information to be relayed with the response"}}}}}},"responses":{"302":{"description":"Redirect to IDP.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/saml/{login_option_id}/slo":{"get":{"tags":["User"],"summary":"SAML ACS/SLO callback, from IDP callback to SP(dashboard)","operationId":"SAMLSLO","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"SAMLResponse","in":"query","required":true,"schema":{"type":"string"},"description":"Base64 encoded SAML response"},{"name":"RelayState","in":"query","required":false,"schema":{"type":"string"},"description":"State information to be relayed with the response"}],"responses":{"302":{"description":"Redirect to IDP.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"post":{"operationId":"SAMLSLOCallback","tags":["User"],"summary":"SAML ACS/SLO callback, from IDP callback to SP(dashboard)","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","required":["SAMLResponse"],"properties":{"SAMLResponse":{"type":"string","description":"Base64 encoded SAML response"},"RelayState":{"type":"string","description":"State information to be relayed with the response"}}}}}},"responses":{"302":{"description":"Redirect to IDP.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/saml/{login_option_id}/metadata":{"get":{"tags":["User"],"summary":"SP metadata","operationId":"SAMLMetadata","parameters":[{"name":"login_option_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"saml metadata xml response","content":{"application/samlmetadata+xml":{"schema":{"type":"string"}}}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/parse_certificate":{"put":{"tags":["SSL"],"summary":"Parse a SSL certificate","operationId":"parseCertificate","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}},"required":["cert"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of certificates metadata.","items":{"type":"object","properties":{"common_name":{"type":"string"},"subject_alt_names":{"type":"array","items":{"type":"string"}},"snis":{"type":"array","items":{"type":"string"}},"not_before":{"type":"string","format":"date-time","nullable":true},"not_after":{"type":"string","format":"date-time","nullable":true},"subject":{"type":"string"},"issuer":{"type":"string"},"serial_number":{"type":"string"},"signature_algorithm":{"type":"string"},"extensions":{"type":"object","additionalProperties":{"type":"string"},"nullable":true}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/validate_cert_key":{"put":{"tags":["SSL"],"summary":"Validate a SSL certificate and key","operationId":"validateCertKey","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"cert":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."},"key":{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}},"required":["cert","key"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"boolean"}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/contact_points":{"post":{"tags":["Contact Point"],"summary":"Create a ContactPoint","operationId":"createContactPoint","description":"IAM Action: `iam:CreateContactPoint`, Resource: `arn:api7:iam:contactpoint/*`","requestBody":{"content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"oneOf":[{"title":"EmailType","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_config":{"type":"object","properties":{"email":{"type":"array","items":{"type":"string","format":"email"}}}}},"required":["email_config"]},{"title":"WebhookType","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"webhook_config":{"type":"object","properties":{"ssl_verify":{"type":"boolean"},"url":{"type":"string","description":"The Webhook URL.","format":"url","minLength":1,"maxLength":1024},"method":{"type":"string","description":"The HTTP method of the Webhook request.","default":"POST","enum":["POST"]},"headers":{"type":"array","description":"Extra HTTP headers to take when sending requests.","minItems":1,"maxItems":16,"items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[-_a-zA-Z0-9]+$"},"value":{"type":"string","minLength":1,"maxLength":64}}}}}}},"required":["webhook_config"]}]}],"required":["name","type"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"oneOf":[{"title":"EmailType","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_config":{"type":"object","properties":{"email":{"type":"array","items":{"type":"string","format":"email"}}}}},"required":["email_config"]},{"title":"WebhookType","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"webhook_config":{"type":"object","properties":{"ssl_verify":{"type":"boolean"},"url":{"type":"string","description":"The Webhook URL.","format":"url","minLength":1,"maxLength":1024},"method":{"type":"string","description":"The HTTP method of the Webhook request.","default":"POST","enum":["POST"]},"headers":{"type":"array","description":"Extra HTTP headers to take when sending requests.","minItems":1,"maxItems":16,"items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[-_a-zA-Z0-9]+$"},"value":{"type":"string","minLength":1,"maxLength":64}}}}}}},"required":["webhook_config"]}]}],"required":["name","type"]},{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"get":{"tags":["Contact Point"],"summary":"List ContactPoints","operationId":"listContactPoints","description":"IAM Action: `iam:GetContactPoint`, Resource: `arn:api7:iam:contactpoint/%s`","parameters":[{"name":"type","in":"query","schema":{"type":"string","enum":["email","webhook"]}},{"name":"labels","in":"query","required":false,"schema":{"type":"object","additionalProperties":{"type":"string"},"minLength":1}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."},{"name":"order_by","in":"query","schema":{"type":"string","default":"updated_at","enum":["created_at","updated_at"]}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of contact points.","items":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"oneOf":[{"title":"EmailType","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_config":{"type":"object","properties":{"email":{"type":"array","items":{"type":"string","format":"email"}}}}},"required":["email_config"]},{"title":"WebhookType","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"webhook_config":{"type":"object","properties":{"ssl_verify":{"type":"boolean"},"url":{"type":"string","description":"The Webhook URL.","format":"url","minLength":1,"maxLength":1024},"method":{"type":"string","description":"The HTTP method of the Webhook request.","default":"POST","enum":["POST"]},"headers":{"type":"array","description":"Extra HTTP headers to take when sending requests.","minItems":1,"maxItems":16,"items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[-_a-zA-Z0-9]+$"},"value":{"type":"string","minLength":1,"maxLength":64}}}}}}},"required":["webhook_config"]}]}],"required":["name","type"]},{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"}}}]}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/contact_points/{contact_point_id}":{"get":{"tags":["Contact Point"],"summary":"Get a ContactPoint","operationId":"getContactPoint","description":"IAM Action: `iam:GetContactPoint`, Resource: `arn:api7:iam:contactpoint/%s`","parameters":[{"name":"contact_point_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"oneOf":[{"title":"EmailType","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_config":{"type":"object","properties":{"email":{"type":"array","items":{"type":"string","format":"email"}}}}},"required":["email_config"]},{"title":"WebhookType","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"webhook_config":{"type":"object","properties":{"ssl_verify":{"type":"boolean"},"url":{"type":"string","description":"The Webhook URL.","format":"url","minLength":1,"maxLength":1024},"method":{"type":"string","description":"The HTTP method of the Webhook request.","default":"POST","enum":["POST"]},"headers":{"type":"array","description":"Extra HTTP headers to take when sending requests.","minItems":1,"maxItems":16,"items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[-_a-zA-Z0-9]+$"},"value":{"type":"string","minLength":1,"maxLength":64}}}}}}},"required":["webhook_config"]}]}],"required":["name","type"]},{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"put":{"tags":["Contact Point"],"summary":"Update a ContactPoint","operationId":"putContactPoint","description":"IAM Action: `iam:UpdateContactPoint`, Resource: `arn:api7:iam:contactpoint/%s`","parameters":[{"name":"contact_point_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"oneOf":[{"title":"EmailType","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_config":{"type":"object","properties":{"email":{"type":"array","items":{"type":"string","format":"email"}}}}},"required":["email_config"]},{"title":"WebhookType","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"webhook_config":{"type":"object","properties":{"ssl_verify":{"type":"boolean"},"url":{"type":"string","description":"The Webhook URL.","format":"url","minLength":1,"maxLength":1024},"method":{"type":"string","description":"The HTTP method of the Webhook request.","default":"POST","enum":["POST"]},"headers":{"type":"array","description":"Extra HTTP headers to take when sending requests.","minItems":1,"maxItems":16,"items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[-_a-zA-Z0-9]+$"},"value":{"type":"string","minLength":1,"maxLength":64}}}}}}},"required":["webhook_config"]}]}],"required":["name","type"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"allOf":[{"allOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256},"desc":{"description":"The object description.","type":"string","maxLength":65536},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}}}},{"oneOf":[{"title":"EmailType","type":"object","properties":{"type":{"type":"string","enum":["email"]},"email_config":{"type":"object","properties":{"email":{"type":"array","items":{"type":"string","format":"email"}}}}},"required":["email_config"]},{"title":"WebhookType","type":"object","properties":{"type":{"type":"string","enum":["webhook"]},"webhook_config":{"type":"object","properties":{"ssl_verify":{"type":"boolean"},"url":{"type":"string","description":"The Webhook URL.","format":"url","minLength":1,"maxLength":1024},"method":{"type":"string","description":"The HTTP method of the Webhook request.","default":"POST","enum":["POST"]},"headers":{"type":"array","description":"Extra HTTP headers to take when sending requests.","minItems":1,"maxItems":16,"items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","minLength":1,"maxLength":64,"pattern":"^[-_a-zA-Z0-9]+$"},"value":{"type":"string","minLength":1,"maxLength":64}}}}}}},"required":["webhook_config"]}]}],"required":["name","type"]},{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"}}}]}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}},"delete":{"tags":["Contact Point"],"summary":"Delete a ContactPoint","operationId":"deleteContactPoint","description":"IAM Action: `iam:DeleteContactPoint`, Resource: `arn:api7:iam:contactpoint/%s`","parameters":[{"name":"contact_point_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/contact_points/{contact_point_id}/notification_logs":{"get":{"tags":["Contact Point"],"summary":"List notification logs of a ContactPoint","operationId":"listContactPointNotificationLogs","description":"IAM Action: `iam:GetContactPoint`, Resource: `arn:api7:iam:contactpoint/%s`","parameters":[{"name":"contact_point_id","in":"path","required":true,"schema":{"type":"string"}},{"in":"query","name":"start_at","schema":{"type":"integer"}},{"in":"query","name":"end_at","schema":{"type":"integer"}},{"name":"resource_type","in":"query","schema":{"type":"string","enum":["alert_policy","api_product_notification"]}},{"name":"status","in":"query","schema":{"type":"string"}},{"name":"order_by","in":"query","schema":{"type":"string","default":"send_time","enum":["send_time"]}},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of notification list.","items":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"},"contact_point_name":{"type":"string"},"resource_type":{"type":"string","enum":["alert_policy","api_product_notification"]},"resource_id":{"type":"string"},"resource_name":{"type":"string"},"status":{"type":"string"},"send_time":{"type":"integer"},"request":{"type":"string"},"response":{"type":"string"}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/contact_points/{contact_point_id}/usages":{"get":{"tags":["Contact Point"],"summary":"List a ContactPoint usages.","operationId":"getContactPointUsages","description":"IAM Action: `iam:GetContactPoint`, Resource: `arn:api7:iam:contactpoint/%s`","parameters":[{"name":"contact_point_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"resource_type","in":"query","schema":{"type":"string","enum":["alert_policy","api_product_notification"]}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"An array of contact point usages.","items":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"integer"},"updated_at":{"type":"integer"},"resource_type":{"type":"string","enum":["alert_policy","api_product_notification"]},"resource_id":{"type":"string"},"resource_name":{"type":"string"}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/resource_names":{"post":{"tags":["Common"],"summary":"Get name of resources","operationId":"queryResourceNames","requestBody":{"content":{"application/json":{"schema":{"oneOf":[{"title":"NormalResource","type":"object","properties":{"resource_type":{"type":"string","enum":["gateway_group","contact_point"]},"ids":{"type":"array","uniqueItems":true,"minItems":1,"items":{"type":"string","minLength":1}}},"required":["resource_type","ids"],"additionalProperties":false},{"title":"GatewayGroupResource","type":"object","properties":{"resource_type":{"type":"string","enum":["sni","certificate","ca_certificate"]},"ids":{"type":"array","uniqueItems":true,"minItems":1,"items":{"type":"string","minLength":1}},"gateway_group_id":{"type":"string","description":"The gateway group id","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["resource_type","ids","gateway_group_id"],"additionalProperties":false}]}}}},"responses":{"200":{"description":"query resource names","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}},{"type":"object","properties":{"value":{"type":"object","additionalProperties":{"type":"string"}}}}]}}}},"400":{"description":"Invalid arguments. Error details will be provided in the response.","content":{}},"500":{"description":"Internal Server Error","content":{}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/approvals":{"get":{"tags":["Approval"],"summary":"List approvals.","operationId":"listApprovals","description":"For event type `api_product_subscription`: IAM Action: `portal:ApproveAPIProductSubscription`, Resource: `arn:api7:portal:apiproduct/%s` For event type `developer_registration`: IAM Action: `portal:ApproveDeveloperSignUp`, Resource: `arn:api7:portal:developer/*`","parameters":[{"name":"status","in":"query","schema":{"type":"string","enum":["pending","finished"]}},{"name":"result","in":"query","schema":{"type":"string","enum":["accepted","rejected"]}},{"name":"event","in":"query","schema":{"type":"string","enum":["api_product_subscription","developer_registration"]}},{"name":"resource_type","in":"query","schema":{"type":"string","enum":["api_product","developer"]}},{"name":"resource_name","in":"query","schema":{"type":"string"}},{"name":"operator_name","in":"query","schema":{"type":"string"}},{"name":"applicant_name","in":"query","schema":{"type":"string"}},{"name":"page","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page number, starting from 1.","in":"query"},{"name":"page_size","schema":{"type":"integer","format":"int64","minimum":1},"description":"The page size. It must be greater than 0.","in":"query"},{"name":"direction","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"It should be ascending or descending (case-insensitive). By default, it is set to descending.","in":"query"},{"name":"order_by","in":"query","schema":{"type":"string","default":"applied_at","enum":["applied_at","resource_name","operated_at"]}},{"name":"search","in":"query","schema":{"type":"string"},"description":"The search keyword."}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"type":"object","description":"The outer structure for encapsulating a list of resources.","properties":{"list":{"type":"array","items":{"type":"object"}},"total":{"type":"integer","minimum":0}}},{"type":"object","properties":{"list":{"type":"array","description":"The array of approval.","items":{"type":"object","properties":{"id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"created_at":{"description":"The object timestamp.","type":"integer","minimum":0},"updated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"event":{"type":"string","enum":["api_product_subscription","developer_registration"]},"resource_type":{"type":"string","enum":["api_product","developer"]},"resource_id":{"type":"string"},"resource_name":{"type":"string"},"applicant_type":{"type":"string","enum":["developer"]},"applicant_id":{"type":"string","description":"When `applicant_type` == \"developer\", it is the developer ID."},"applicant_name":{"type":"string","description":"When `applicant_type` == \"developer\", it is the developer name."},"applied_at":{"description":"The object timestamp.","type":"integer","minimum":0},"result":{"type":"string","enum":["accepted","rejected"]},"operator_id":{"type":"string","description":"Operator user ID."},"operator_name":{"type":"string","description":"Operator user name."},"operated_at":{"description":"The object timestamp.","type":"integer","minimum":0},"status":{"type":"string","enum":["pending","finished"]}}}}}}]}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/approvals/{approval_id}/accept":{"post":{"tags":["Approval"],"summary":"Accept an approval.","operationId":"acceptApproval","description":"For event type `api_product_subscription`: IAM Action: `portal:ApproveAPIProductSubscription`, Resource: `arn:api7:portal:apiproduct/%s` For event type `developer_registration`: IAM Action: `portal:ApproveDeveloperSignUp`, Resource: `arn:api7:portal:developer/*`","parameters":[{"name":"approval_id","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}},"/api/approvals/{approval_id}/reject":{"post":{"tags":["Approval"],"summary":"Accept an approval.","operationId":"rejectApproval","description":"For event type `api_product_subscription`: IAM Action: `portal:ApproveAPIProductSubscription`, Resource: `arn:api7:portal:apiproduct/%s` For event type `developer_registration`: IAM Action: `portal:ApproveDeveloperSignUp`, Resource: `arn:api7:portal:developer/*`","parameters":[{"name":"approval_id","in":"path","required":true,"schema":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}},"400":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"error_msg":{"type":"string","description":"The error message."}}}}}},"default":{"description":"","content":{"application/json":{"schema":{"type":"object","description":"The outer structure for encapsulating the specific resource.","properties":{"value":{"type":"object","description":"The specific resource."},"warning_msg":{"type":"string","description":"The warning message."}}}}}}}}}},"components":{"schemas":{"HTTPService":{"type":"object","required":["name"],"properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"type":{"type":"string","enum":["http","stream"],"default":"http"},"hosts":{"type":"array","description":"The hosts for the service to accept incoming requests.","uniqueItems":true,"minItems":1,"maxItems":32,"items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"path_prefix":{"maxLength":4096,"minLength":1,"pattern":"^/","type":"string","description":"The listening path prefix of the service."},"strip_path_prefix":{"type":"boolean","default":true,"description":"Weather strip the path prefix or not when proxying the request to the upstream."},"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]}}},"StreamService":{"type":"object","required":["name"],"properties":{"name":{"maxLength":65536,"description":"The object name.","type":"string","minLength":1},"labels":{"type":"object","additionalProperties":{"type":"string","pattern":"^.+$","minLength":1,"maxLength":65536},"example":{"keyA":"valueA","keyB":"valueB"}},"desc":{"description":"The object description.","type":"string","maxLength":65536},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"},"type":{"type":"string","enum":["stream"]},"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]}}},"HTTPServiceRuntimeConfiguration":{"type":"object","minProperties":1,"properties":{"hosts":{"type":"array","description":"The hosts for the service to accept incoming requests.","uniqueItems":true,"minItems":1,"maxItems":32,"items":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"}},"path_prefix":{"maxLength":4096,"minLength":1,"pattern":"^/","type":"string","description":"The listening path prefix of the service."},"strip_path_prefix":{"type":"boolean","default":true,"description":"Weather strip the path prefix or not when proxying the request to the upstream."},"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The upstream name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `http`.","type":"string","enum":["http","https","grpc","grpcs"],"default":"http"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"retries":{"description":"The number of retries while passing the request to an upstream using the underlying Nginx mechanism.","minimum":0,"maximum":65535,"type":"integer"},"keepalive_pool":{"description":"The upstream separate connection pool.","type":"object","properties":{"size":{"description":"Sets keepalive directive dynamically.","minimum":1,"type":"integer","default":320},"idle_timeout":{"description":"Sets keepalive_timeout directive dynamically.","minimum":0,"type":"number","format":"float","default":60},"requests":{"description":"Sets keepalive_requests directive dynamically.","minimum":1,"type":"integer","default":1000}}},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"retry_timeout":{"description":"Timeout to continue with retries. Setting this to 0 disables the retry timeout.","type":"number","format":"float","minimum":0,"default":0},"pass_host":{"type":"string","description":"Define how to decide the host header before forwarding requests to an upstream.\n* `pass` uses the host specified in the service.\n* `node` uses the host specified in the upstream.\n* `rewrite` uses custom host.","enum":["pass","node","rewrite"],"default":"pass"},"upstream_host":{"description":"Only valid if the `pass_host` is `rewrite`. It indicates what value to rewrite the host header to.","type":"string","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"service_name":{"description":"Only valid for service discovery. Used to indicate how services are discovered in the service registry.","type":"string","minLength":1,"maxLength":256,"example":"<ServiceRegistryID>/public/group/httpbin"},"discovery_type":{"type":"string","description":"Only valid for service discovery.","enum":["kubernetes","nacos"]},"discovery_args":{"description":"Only valid for service discovery.","type":"object","properties":{"metadata":{"type":"object","additionalProperties":{"type":"string"},"example":{"idc":"shanghai"}}}},"tls":{"deprecated":true,"description":"Replace with `client_certificate` and `ca_certificates`","oneOf":[{"properties":{"client_cert":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The certificate in PEM format."}]},"client_key":{"oneOf":[{"type":"string","pattern":"^\\$(secret|env|ENV)://"},{"type":"string","minLength":1,"maxLength":65536,"pattern":"^[^\\$]","description":"The private key in PEM format."}]}},"required":["client_cert","client_key"]},{"properties":{"client_cert_id":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"required":["client_cert_id"]}]},"client_certificate":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256},"ca_certificates":{"type":"array","items":{"description":"The object ID.","type":"string","pattern":"^[a-zA-Z0-9-_.]+$","minLength":1,"maxLength":256}},"tls_verify":{"type":"boolean"},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]},{"anyOf":[{"required":["nodes"],"title":"UseUpstreamNodes"},{"required":["service_name","discovery_type"],"title":"UseServiceRegistry"},{"required":["service_name","discovery_type","discovery_args"],"title":"UseServiceRegistryWithArgs"}]}]},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},"StreamServiceRuntimeConfiguration":{"type":"object","minProperties":1,"properties":{"upstream":{"description":"The upstream contains necessary information for the gateway to proxy\nrequest to the backend service.\n","allOf":[{"type":"object","properties":{"name":{"default":"default","maxLength":65536,"description":"The object name.","type":"string","minLength":1},"scheme":{"description":"The protocol that is used for communicating with the backend service when the service type is `stream`.","type":"string","enum":["tcp","udp"],"default":"tcp"},"desc":{"description":"The object description.","type":"string","maxLength":65536},"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","default":"roundrobin"},"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"nodes":{"maxItems":64,"type":"array","description":"The upstream endpoints.","items":{"description":"The definition for an upstream endpoint.","required":["host","port","weight"],"type":"object","properties":{"host":{"pattern":"^\\\\*?[0-9a-zA-Z-._]+$","type":"string","example":"httpbin.org"},"port":{"maximum":65535,"minimum":1,"type":"integer","example":8080},"weight":{"maximum":65535,"minimum":0,"type":"integer","example":100},"priority":{"description":"The node priority.","type":"integer","default":0}}}},"checks":{"type":"object","description":"The health check data.","anyOf":[{"required":["active"]},{"required":["active","passive"]}],"properties":{"active":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"timeout":{"type":"number","format":"float","default":1,"description":"The timeout period of the active check (in second)."},"concurrency":{"type":"integer","format":"int64","default":10,"description":"The number of targets to be checked at the same time during the active check."},"host":{"type":"string","description":"The HTTP host.","pattern":"^\\*?[0-9a-zA-Z-._]+$","example":"httpbin.org"},"port":{"type":"integer","minimum":1,"maximum":65535,"format":"int64","description":"By default, the port is the same as the one defined in the upstream target."},"http_path":{"type":"string","default":"/","description":"The HTTP path in HTTP probe requests."},"https_verify_certificate":{"type":"boolean","description":"Whether to verify the target's TLS certificate.","default":true},"req_headers":{"type":"array","description":"The request headers.","minItems":1,"uniqueItems":true,"items":{"type":"string","description":"format -> key: value, for example, user-agent: go/1.20"}},"healthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking healthy targets (in seconds)."},"http_statuses":{"default":[200,302],"type":"array","minItems":1,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":1,"type":"integer","default":2,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"interval":{"default":1,"minimum":1,"type":"integer","format":"int64","description":"The time interval for checking unhealthy targets (in seconds)."},"http_statuses":{"type":"array","default":[429,404,500,501,502,503,504,505],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"http_failures":{"minimum":1,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."},"tcp_failures":{"minimum":1,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":1,"maximum":254,"default":3,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."}}}}},"passive":{"type":"object","properties":{"type":{"type":"string","enum":["http","https","tcp"],"default":"http"},"healthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,306,307,308],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is successful.","items":{"minimum":200,"maximum":599,"type":"integer"}},"successes":{"minimum":0,"type":"integer","default":5,"format":"int64","description":"The number of successful probes to define a healthy target."}}},"unhealthy":{"type":"object","properties":{"http_statuses":{"type":"array","default":[429,500,503],"minItems":1,"uniqueItems":true,"description":"A list of HTTP status codes. It's used for checking if an HTTP probe request is failed.","items":{"minimum":200,"maximum":599,"type":"integer"}},"tcp_failures":{"minimum":0,"maximum":254,"type":"integer","default":2,"format":"int64","description":"The number of TCP-related failures to define an unhealthy target."},"timeouts":{"minimum":0,"maximum":254,"default":7,"type":"integer","format":"int64","description":"The number of probe timeouts to define an unhealthy target."},"http_failures":{"minimum":0,"maximum":254,"type":"integer","default":5,"format":"int64","description":"The number of HTTP-related failures to define an unhealthy target."}}}}}}}}},{"oneOf":[{"title":"ConsistentHashingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.  When the value is `chash`, the `hash_on` and `key` fields need to be assigned.","enum":["chash"]},"hash_on":{"description":"Only valid if the type is `chash`.  Define what to use as hashing input. Supports Nginx variables (`vars`), custom headers (`header`), `cookie`, `consumer`, `vars_combinations`. Defaults to vars.","type":"string","enum":["vars","header","cookie","consumer","vars_combinations"],"default":"vars"},"key":{"type":"string","description":"The key is used for consistent hash, which can be combined using variables, such as $host$uri. Finds the corresponding node id according to hash_on and key values. When hash_on is set to vars,  key is a required parameter and it supports Nginx variables. When hash_on is set as header,  key is a required parameter, and header name can be customized. When hash_on is set to cookie,  key is also a required parameter, and cookie name can be customized. When hash_on is set to consumer,  key need not be set and the key used by the hash algorithm would be the authenticated consumer_name.","minLength":1}}},{"title":"OtherLoadBalancingAlgorithm","type":"object","properties":{"type":{"type":"string","description":"The load balancing algorithm to distribute traffic to targets.","enum":["roundrobin","least_conn","ewma"]}}}]}]},"status":{"description":"The object status. 1 means the object is active while 0 means it's inactive.\n","type":"integer","enum":[0,1]},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},"RouteRuntimeConfiguration":{"type":"object","additionalProperties":false,"properties":{"timeout":{"description":"The timeout settings for connecting to, and sending and receiving messages to and from the upstream (in seconds).","type":"object","properties":{"connect":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"send":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60},"read":{"minimum":0,"exclusiveMinimum":true,"type":"integer","default":60}}},"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}},"StreamRouteRuntimeConfiguration":{"type":"object","additionalProperties":false,"properties":{"plugins":{"description":"The key-value pairs which represent the plugins attached on the object.","type":"object"}}}},"securitySchemes":{"APIKeyAuth":{"type":"apiKey","in":"header","name":"X-API-KEY"},"BasicAuth":{"type":"http","scheme":"basic"}}}}