Skip to content

Commit

Permalink
Updated API from documentation release
Browse files Browse the repository at this point in the history
  • Loading branch information
Auto Mation committed Oct 25, 2023
1 parent 0f29272 commit 118a45b
Show file tree
Hide file tree
Showing 9 changed files with 97 additions and 22 deletions.
8 changes: 3 additions & 5 deletions api-specs/connect/api.raml
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ resourceTypes: !include types/resource-types.raml
responses:
200:
body:
type: common.Paged
type: DeploymentPagedQueryResponse
properties:
results: Deployment[]
example: !include ./examples/deployment/paged.json
Expand Down Expand Up @@ -238,7 +238,7 @@ resourceTypes: !include types/resource-types.raml
responses:
200:
body:
type: common.Paged
type: ConnectorSearchPagedQueryResponse
properties:
results: Connector[]
example: !include ./examples/connector/paged.json
Expand Down Expand Up @@ -280,9 +280,7 @@ resourceTypes: !include types/resource-types.raml
responses:
200:
body:
type: common.Paged
properties:
results: ConnectorStaged[]
type: ConnectorStagedPagedQueryResponse
example: !include ./examples/connector/staged-paged.json
/{ID}:
(annotations.methodName): withId
Expand Down
3 changes: 2 additions & 1 deletion api-specs/connect/examples/connector/staged-paged.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@
"status": "Draft",
"publishingReport": null,
"isPreviewable": "none",
"previewableReport": null
"previewableReport": null,
"certified": true
}
]
}
15 changes: 0 additions & 15 deletions api-specs/connect/types/common.raml
Original file line number Diff line number Diff line change
Expand Up @@ -397,21 +397,6 @@ types:
pattern: ^[a-zA-Z0-9-_.]+:[a-zA-Z0-9-_]{2,36}$
description: Identifies a Composable Commerce Project. Uses the format "{region}:{projectKey}".
example: europe-west1.gcp:my-project-key
Paged:
description: |
A Paged Result.
properties:
limit: number
offset: number
count: number
total: number
results: any
CursorPaged:
description: |
A Cursor Paged Result.
properties:
data: any
next: string
IsPreviewable:
type: string
description: |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#%RAML 1.0 DataType
(annotations.package): Connector
displayName: ConnectorSearchPagedQueryResponse
description: |
[PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of [Connector](ctp:connect:type:Connector).
properties:
limit:
type: number
format: int64
description: The maximum number of Connectors returned.
offset:
type: number
format: int64
description: The offset of the Connectors returned.
count:
type: number
format: int64
description: The number of Connectors returned.
total:
type: number
format: int64
description: The total number of Connectors matching the query.
results:
type: Connector[]
description: Connectors matching the query.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#%RAML 1.0 DataType
(annotations.package): Connector
displayName: ConnectorStagedPagedQueryResponse
description: |
[PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of [ConnectorStaged](ctp:connect:type:ConnectorStaged).
properties:
limit:
type: number
format: int64
description: The maximum number of the ConnectorStaged returned.
offset:
type: number
format: int64
description: The offset of the ConnectorStaged returned.
count:
type: number
format: int64
description: The number of ConnectorStaged returned.
total:
type: number
format: int64
description: The total number of ConnectorStaged matching the query.
results:
type: ConnectorStaged[]
description: ConnectorStaged matching the query.
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#%RAML 1.0 DataType
(annotations.package): Deployment
displayName: DeploymentLogCursorPagedQueryResponse
description: |
A cursor paged query result containing an array of [DeploymentLog](ctp:connect:type:DeploymentLog).
properties:
data:
type: DeploymentLog[]
description: Array of DeploymentLog objects.
next:
type: string
description: The next page token.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#%RAML 1.0 DataType
(annotations.package): Deployment
displayName: DeploymentPagedQueryResponse
description: |
[PagedQueryResult](/../api/general-concepts#pagedqueryresult) with results containing an array of [Deployment](ctp:connect:type:Deployment).
properties:
limit:
type: number
format: int64
description: The limit of the Deployments returned.
offset:
type: number
format: int64
description: The offset of the Deployments returned.
count:
type: number
format: int64
description: The number of Deployments returned.
total:
type: number
format: int64
description: The total number of Deployments available.
results:
type: Deployment[]
description: Deployments matching the query.
2 changes: 1 addition & 1 deletion api-specs/connect/types/resource-types.raml
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ deploymentLogs:
responses:
200:
body:
type: common.CursorPaged
type: DeploymentLogCursorPagedQueryResponse
properties:
data: DeploymentLog[]
example: !include ../examples/deployment-log/cursor-paged.json
4 changes: 4 additions & 0 deletions api-specs/connect/types/types.raml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
Connector: !include connector/connector.raml
ConnectorDraft: !include connector/connector-draft.raml
ConnectorStaged: !include connector/connector-staged.raml
ConnectorStagedPagedQueryResponse: !include connector/connector-staged-paged-query-response.raml
ConnectorSearchPagedQueryResponse: !include connector/connector-search-paged-query-response.raml
ConnectorUpdate: !include connector/connector-update.raml
ConnectorUpdateAction: !include connector/connector-update-action.raml
ConnectorSetCreatorCompanyAction: !include connector/updates/connector-set-company-action.raml
Expand All @@ -24,11 +26,13 @@ ConnectorUpdatePreviewableAction: !include connector/updates/connector-update-pr
ConnectorPublishAction: !include connector/updates/connector-publish-action.raml
# Deployment
Deployment: !include deployment/deployment.raml
DeploymentPagedQueryResponse: !include deployment/deployment-paged-query-response.raml
DeploymentDraft: !include deployment/deployment-draft.raml
DeploymentUpdate: !include deployment/deployment-update.raml
DeploymentUpdateAction: !include deployment/deployment-update-action.raml
DeploymentRedeployAction: !include deployment/updates/deployment-redeploy-action.raml
DeploymentLog: !include deployment/deployment-log.raml
DeploymentLogCursorPagedQueryResponse: !include deployment/deployment-log-cursor-paged-query-response.raml

# Error
ErrorObject: !include error/ErrorObject.raml
Expand Down

0 comments on commit 118a45b

Please sign in to comment.