RDSC-5669 Publish RDI Cloud API reference#3562
Conversation
🛡️ Jit Security Scan Results✅ No security findings were detected in this PR
Security scan by Jit
|
a347f6b to
be6f28d
Compare
cmilesb
left a comment
There was a problem hiding this comment.
I already mentioned it in our Slack DMs, but it doesn't seem like there's an easy way to keep the data/api file updated. Are we just going to replace the file every time the API get changed? We call the Swagger so that we can keep the docs up to date with what's actually deployed.
@paoloredis - Can you look at the updated workflow to make sure there isn't anything broken or weird?
cmilesb
left a comment
There was a problem hiding this comment.
@paoloredis This is specifically for the Redis Cloud RDI stuff, so it should go in the Redis Cloud API reference.
| def enrich_rdi_workspace_docs: | ||
| .components.schemas.WorkspaceCreateRequest.description //= "Request to provision a data integration workspace for a Redis Cloud subscription." | ||
| | .components.schemas.WorkspaceCreateRequest.properties.cidr.description //= "CIDR block for the workspace deployment network." | ||
| | .components.schemas.WorkspacesResponse.description //= "Response containing data integration workspaces in the Redis Cloud account." | ||
| | .components.schemas.WorkspacesResponse.properties.workspaces.description //= "Data integration workspaces." | ||
| | .components.schemas.WorkspaceTasksResponse.description //= "Response containing asynchronous workspace tasks." | ||
| | .components.schemas.WorkspaceTasksResponse.properties.tasks.description //= "Workspace tasks." | ||
| | .components.schemas.WorkspaceTaskResponse.description //= "Asynchronous task created by a workspace operation." | ||
| | .components.schemas.WorkspaceTaskResponse.properties.taskId.description //= "Workspace task ID." | ||
| | .components.schemas.WorkspaceTaskResponse.properties.commandType.description //= "Workspace operation that created the task." | ||
| | .components.schemas.WorkspaceTaskResponse.properties.status.description //= "Current task status." | ||
| | .components.schemas.WorkspaceTaskResponse.properties.description.description //= "Human-readable task status or failure details." | ||
| | .components.schemas.WorkspaceTaskResponse.properties.timestamp.description //= "Time when the task status was recorded." | ||
| | .components.schemas.WorkspaceTaskResponse.properties.response.description //= "Task result payload. Completed workspace tasks can include the current workspace response." | ||
| | .components.schemas.WorkspaceTaskResponse.properties._links.description //= "Links to the task and affected workspace resource." | ||
| | .components.schemas.TaskLinks.description //= "Links related to a workspace task." | ||
| | .components.schemas.TaskLinks.properties.task.description //= "Link to the workspace task." | ||
| | .components.schemas.TaskLinks.properties.resource.description //= "Link to the affected workspace resource." | ||
| | .components.schemas.TaskLink.description //= "Hypermedia link." | ||
| | .components.schemas.TaskLink.properties.href.description //= "Link URL." | ||
| | .components.schemas.TaskLink.properties.type.description //= "Linked resource type." | ||
| | .components.schemas.WorkspaceResponse.description //= "Current data integration workspace state for a subscription." | ||
| | .components.schemas.WorkspaceResponse.properties.subscriptionId.description //= "Redis Cloud subscription ID." | ||
| | .components.schemas.WorkspaceResponse.properties.bdbId.description //= "Redis database ID associated with the workspace." | ||
| | .components.schemas.WorkspaceResponse.properties.rcpClusterId.description //= "RCP cluster ID that hosts workspace resources." | ||
| | .components.schemas.WorkspaceResponse.properties.region.description //= "Cloud provider region where the workspace is deployed." | ||
| | .components.schemas.WorkspaceResponse.properties.vpcId.description //= "VPC ID used by the workspace." | ||
| | .components.schemas.WorkspaceResponse.properties.createdAt.description //= "Time when the workspace record was created." | ||
| | .components.schemas.WorkspaceResponse.properties.infrastructure.description //= "Provisioned infrastructure state and connection details." | ||
| | .components.schemas.WorkspaceResponse.properties.capabilities.description //= "Workspace features available in the current state." | ||
| | .components.schemas.InfrastructureResponse.description //= "Provisioned infrastructure state for a data integration workspace." | ||
| | .components.schemas.InfrastructureResponse.properties.state.description //= "Workspace infrastructure state." | ||
| | .components.schemas.InfrastructureResponse.properties.cidr.description //= "CIDR block assigned to the workspace deployment network." | ||
| | .components.schemas.InfrastructureResponse.properties.timestamps.description //= "Infrastructure lifecycle timestamps." | ||
| | .components.schemas.InfrastructureResponse.properties.iam.description //= "IAM values used by workspace integrations." | ||
| | .components.schemas.InfrastructureResponse.properties.networking.description //= "Workspace networking outputs." | ||
| | .components.schemas.InfrastructureResponse.properties.monitoring.description //= "Workspace monitoring endpoints." | ||
| | .components.schemas.InfrastructureResponse.properties.error.description //= "Infrastructure error details when the workspace is in a failed state." | ||
| | .components.schemas.InfrastructureTimestamps.description //= "Workspace infrastructure lifecycle timestamps." | ||
| | .components.schemas.InfrastructureTimestamps.properties.startedAt.description //= "Time when infrastructure provisioning started." | ||
| | .components.schemas.InfrastructureTimestamps.properties.updatedAt.description //= "Time when infrastructure state was last updated." | ||
| | .components.schemas.InfrastructureIam.description //= "IAM values produced for workspace integrations." | ||
| | .components.schemas.InfrastructureIam.properties.privateLinkAllowedPrincipal.description //= "AWS principal allowed to connect to the workspace PrivateLink endpoint service." | ||
| | .components.schemas.InfrastructureIam.properties.secretsRoleArn.description //= "AWS IAM role ARN used to read workspace secrets." | ||
| | .components.schemas.NetworkingOutput.description //= "Workspace networking outputs." | ||
| | .components.schemas.NetworkingOutput.properties.egressIps.description //= "Outbound IP addresses used by workspace components." | ||
| | .components.schemas.NetworkingOutput.properties.availabilityZones.description //= "Availability zones used by workspace infrastructure." | ||
| | .components.schemas.MonitoringOutput.description //= "Workspace monitoring outputs." | ||
| | .components.schemas.MonitoringOutput.properties.metricsUrls.description //= "Metrics endpoint URLs for workspace components." | ||
| | .components.schemas.MetricsUrls.description //= "Metrics endpoint URLs for RDI workspace components." | ||
| | .components.schemas.MetricsUrls.properties.rdiOperatorUrl.description //= "Metrics endpoint URL for the RDI operator." | ||
| | .components.schemas.MetricsUrls.properties.rdiProcessorUrl.description //= "Metrics endpoint URL for the RDI processor." | ||
| | .components.schemas.MetricsUrls.properties.collectorSourceUrls.description //= "Metrics endpoint URLs for deployed collector sources, keyed by source name." | ||
| | .components.schemas.InfrastructureError.description //= "Infrastructure failure details." | ||
| | .components.schemas.InfrastructureError.properties.code.description //= "Machine-readable error code." | ||
| | .components.schemas.InfrastructureError.properties.message.description //= "Human-readable error message." | ||
| | .components.schemas.InfrastructureError.properties.timestamp.description //= "Time when the error was recorded." | ||
| | .components.schemas.InfrastructureError.properties.details.description //= "Additional structured error details." | ||
| | .components.schemas.Capabilities.description //= "Workspace capabilities available in the current state." | ||
| | .components.schemas.Capabilities.properties.validateSecrets.description //= "Whether the workspace can validate secret ARNs." | ||
| | .components.schemas.Capabilities.properties.validatePrivateLink.description //= "Whether the workspace can validate PrivateLink endpoint service names." | ||
| | .components.schemas.Capabilities.properties.readyForPipeline.description //= "Whether the workspace is ready to create and deploy RDI pipelines." | ||
| | .components.schemas.Capabilities.properties.createPrivateLink.description //= "Whether the workspace can create PrivateLink endpoints."; |
There was a problem hiding this comment.
Why is all of this stuff added here and is not part of the rdi json file in the first place?
There was a problem hiding this comment.
The goal was that CAPI exposes functionality not just of the cloud database but all applications as well. So for example, the RDI API is accessible under the CAPI Pro subscriptions path, so on one side it makes sense to document the RDI API in the same place.
If you think we should separate the docs reference, we can also discuss that approach.
TBH I don't have a strong opinion.
Summary
Subscriptions - Pro - Data Integrationapi.redislabs.comand compose them into one reference fileJira
https://redislabs.atlassian.net/browse/RDSC-5669
Replaces
#3561
Validation
https://api.redislabs.com/v1/cloud-api-docs/capiandhttps://api.redislabs.com/v1/cloud-api-docs/rdi, composed them with the workflow jq logic, and regeneratedcontent/operate/rc/api/api-reference/openapi.json.jq empty content/operate/rc/api/api-reference/openapi.json..github/workflows/rc_api_sync.yamlparses as YAML.hugo --logLevel warn --gc; it still fails on an unrelated commands navigation template issue:layouts/partials/docs-nav.htmlcannot evaluateByWeightin[]interface{}while renderingcontent/commands/acl.md.