Help Center> ServiceStage> API Reference> CSE API> Schema> Querying the Schema Information About a Microservice

Querying the Schema Information About a Microservice

Function

This API is used to query the schema information about a microservice based on the service and schema IDs.

Constraints

None

URI

GET /v4/{project_id}/registry/microservices/{service_id}/schemas/{schema_id}

Table 1 Path parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Unique ID of a tenant sub-project. Length: 1–64 characters.

service_id

Yes

String

Microservice ID, which must be unique. Length: 1–64 characters. Regular expression: ^.*$

schema_id

Yes

String

Schema ID.

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

x-domain-name

Yes

String

Tenant account name.

Response Parameters

Status code: 200

Table 3 Response header parameters

Parameter

Type

Description

X-Schema-Summary

String

Microservice schema summary.

Table 4 Response body parameters

Parameter

Type

Description

schema

String

Microservice schema content.

Status code: 400

Table 5 Response body parameters

Parameter

Type

Description

errorCode

String

Error code.

errorMessage

String

Error information.

detail

String

Location details.

Status code: 500

Table 6 Response body parameters

Parameter

Type

Description

errorCode

String

Error code.

errorMessage

String

Error information.

detail

String

Location details.

Example Requests

GET https://{endpoint}/v4/{project_id}/registry/microservices/{service_id}/schemas/{schema_id}

Example Responses

Status code: 200

OK (If the summary exists, the value of X-Schema-Summary in the header is the summary of the schema.)

"{\n  \"schema\": \"string\"\n}"

Status Codes

Status Code

Description

200

OK (If the summary exists, the value of X-Schema-Summary in the header is the summary of the schema.)

400

Bad Request

500

Internal Server Error

Error Codes

See Error Codes.