openapi: 3.0.1 info: title: Cloud2Cloud Connector API description: "Provides API to maintenance linked clouds and linked accounts." license: name: Apache 2.0 url: http://www.apache.org/licenses/LICENSE-2.0.html version: 1.0.0 tags: - name: Clouds description: Actions over linked clouds - name: Accounts description: Actions over linked accounts - name: Events description: Actions over coming events paths: /api/v1/clouds: post: tags: - Clouds summary: Create linked cloud operationId: createCloud requestBody: description: Linked cloud object that needs to be added to the store content: application/json: schema: $ref: "#/components/schemas/LinkedCloud" required: true responses: 200: description: successful operation content: application/json: schema: $ref: "#/components/schemas/LinkedCloud" security: - c2c_connector_auth: - empty get: tags: - Clouds summary: List linked clouds operationId: listClouds responses: 200: description: successful operation content: application/json: schema: type: object properties: cloudId: $ref: "#/components/schemas/LinkedClouds" security: - c2c_connector_auth: - empty /api/v1/clouds/{cloudId}: delete: tags: - Clouds summary: Delete linked cloud parameters: - $ref: "#/components/parameters/cloudId" responses: 200: description: successful operation security: - c2c_connector_auth: - empty /api/v1/clouds/{cloudId}/accounts: get: tags: - Accounts summary: Create linked account parameters: - $ref: "#/components/parameters/cloudId" responses: 307: description: redirect to get authorization code security: - c2c_connector_auth: - empty /api/v1/clouds/{cloudId}/accounts/{accountId}: delete: tags: - Accounts summary: Delete linked account parameters: - $ref: "#/components/parameters/cloudId" - $ref: "#/components/parameters/accountId" responses: 200: description: successful operation security: - c2c_connector_auth: - empty /api/v1/oauthCallback: get: tags: - Accounts summary: Used for get authorization code for linked account parameters: - $ref: "#/components/parameters/{oauthCallback}" responses: 200: description: redirect to get authorization code /api/v1/events: $ref: "https://raw.githubusercontent.com/openconnectivityfoundation/core-extensions/ocfcloud-openapi/swagger2.0/oic.r.cloudopenapi.swagger.json#/paths/%2F%7BeventsUrl%7D" components: schemas: LinkedClouds: type: object properties: cloud: $ref: "#/components/schemas/LinkedCloud" LinkedCloud: type: object properties: id: type: string format: uuid name: type: string oauth: type: object properties: clientId: type: string clientSecret: type: string scopes: type: array items: type: string authUrl: type: string tokenUrl: type: string authStyle: type: string enum: [autoDetect, inParams, inHeader] audience: type: string redirectUrl: type: string accessType: type: string responseType: type: string responseMode: type: string supportedSubscriptionEvents: type: object properties: devices: type: array items: type: string enum: [ devices_online, devices_offline, devices_registered, devices_unregistered, ] device: type: array items: type: string enum: [resources_published, resources_unpublished] resource: type: array items: type: string enum: [resource_contentchanged] staticDeviceEvents: type: boolean endpoint: type: object properties: url: type: string rootCas: type: array items: type: string insecureSkipVerify: type: boolean useSystemCas: type: boolean securitySchemes: c2c_connector_auth: type: oauth2 flows: implicit: authorizationUrl: http://oauth/connect/token scopes: empty: value parameters: cloudId: name: cloudId in: path description: Id of the cloud required: true schema: type: string format: uuid accountId: name: accountId in: path description: Id of the account required: true schema: type: string format: uuid oauthCallback: name: oauthCallback schema: type: string in: path required: true