API Documentation
According to actual business needs, we generally divide APIs into three types: standard K8S API, advanced API, and CRD (Custom Resource Definition). Therefore, the directory structure is usually organized as follows:
K8S API
Standard K8S API
Refer to DaemonSet.
CRD
Refer to ArtifactCleanupRun.
props
name: Reference name under OpenAPI schemadefinitions(v2) orcomponents/schemas(v3), or CRDmetadata.namenamespaced: Indicates whether the resource is namespace-scoped; defaults totrue, meaning the API Endpoints include the namespace path parameternamespaces/{namespace}pathPrefix: Can be used to override the global configurationapi.pathPrefixfilepath: Similar to specifying openapi path, used to specify a particular openapi or CRD fileapiGroup: Optional, specifies the API group; openapi will try to read the referencedx-kubernetes-group-version-kind, same belowapiVersion: Optional, specifies the API version; CRD defaults to using the first version inspec.versionsapiKind: Optional, specifies the API resource kind
Advanced API
Refer to CodeQualityTaskSummary.
props
path: Path under OpenAPI schemapathspathPrefix: Can be used to override the global configurationapi.pathPrefixopenapiPath: See specifying openapi path
Common References
Refer to CodeQuality.
props
schema: Reference name under OpenAPI schemadefinitions(v2) orcomponents/schemas(v3)openapiPath: See specifying openapi path
Specifying openapi Path
For OpenAPIPath and OpenAPIRef components, by default, the system searches through all openapi definition files until a match is found. If you need to specify a particular openapi file, you can use the openapiPath property: