openapi: 3.2.0 info: title: Consumer connectivity Data balances API description: '#### Copyright © Aeris Communications, Inc.' version: 2.0.1 x-api-id: 7d04b81f-0545-4c01-9d81-244fda13b6c8 x-audience: external-public servers: - url: https://iot-api.aeris.com/iot/api/consumer-connectivity description: API server security: - Oauth2_auth: [] tags: - name: Data balances paths: /data-balances/{company-id}/{subscription-id-type}/{subscription-id}: get: tags: - Data balances summary: Get data balance of a subscription description: Returns data balance of a subscription. operationId: getDataBalanceBySubscription parameters: - name: company-id in: path description: Company ID of the subscription. required: true schema: type: string - name: subscription-id-type in: path description: Subscription ID type required: true schema: $ref: '#/components/schemas/SubscriptionIdTypeEnum' - name: subscription-id in: path description: Subscription ID required: true schema: type: string responses: 200: description: Data balance allOf: - $ref: '#/components/responses/RateLimitedResponse' content: application/vnd.dcp-v1+json: schema: $ref: '#/components/schemas/DataBalance' 400: description: Invalid subscription content: application/vnd.dcp-v1+json: schema: $ref: '#/components/schemas/ErrorResponse' 401: $ref: '#/components/responses/Unauthorized' 404: description: Company or subscription not found content: application/vnd.dcp-v1+json: schema: $ref: '#/components/schemas/ErrorResponse' 429: $ref: '#/components/responses/Response_429' 500: $ref: '#/components/responses/InternalError' security: - Oauth2_auth: - cc.read components: headers: X-RateLimit-Remaining-Minute: description: The number of requests remaining in a minute. schema: type: integer format: int32 X-RateLimit-Limit-Second: description: The maximum number of requests allowed in a second. schema: type: integer format: int32 X-RateLimit-Limit-Minute: description: The maximum number of requests allowed in a minute. schema: type: integer format: int32 Content-Type: description: Handle Content-Type schema: type: string X-RateLimit-Remaining-Second: description: The number of requests remaining in a second. schema: type: integer format: int32 schemas: BucketDataModel: type: object properties: company_id: type: string imsi: type: string msisdn: type: string product_id: type: string purchase_id: type: string format: uuid instance_id: type: string bucket_type: type: string instance_type: type: string volume: type: integer format: int64 balance: type: integer format: int64 end_date: type: string format: date-time created: type: string format: date-time description: Bucket data DataBalance: type: object properties: buckets: type: array items: $ref: '#/components/schemas/BucketDataModel' description: Data balance ErrorResponse: type: object properties: code: type: integer format: int32 http_status: type: integer format: int32 default: 500 message: type: string description: Error response SubscriptionIdTypeEnum: type: string description: Subscription ID type enum: - IMSI - MSISDN responses: InternalError: description: Internal error content: application/vnd.dcp-v1+json: schema: $ref: '#/components/schemas/ErrorResponse' Unauthorized: description: Unauthorized content: application/vnd.dcp-v1+json: schema: $ref: '#/components/schemas/ErrorResponse' Response_429: description: Too Many Requests allOf: - $ref: '#/components/responses/RateLimitedResponse' content: application/vnd.dcp-v1+json: schema: $ref: '#/components/schemas/ErrorResponse' RateLimitedResponse: headers: X-RateLimit-Limit-Second: $ref: '#/components/headers/X-RateLimit-Limit-Second' X-RateLimit-Limit-Minute: $ref: '#/components/headers/X-RateLimit-Limit-Minute' X-RateLimit-Remaining-Second: $ref: '#/components/headers/X-RateLimit-Remaining-Second' X-RateLimit-Remaining-Minute: $ref: '#/components/headers/X-RateLimit-Remaining-Minute' Content-Type: $ref: '#/components/headers/Content-Type' securitySchemes: Oauth2_auth: flows: password: tokenUrl: https://iot-api.aeris.com/iot/api/auth/token scopes: cc.read: Access right needed to read from Consumer Connectivity service. cc.write: Access right needed to write to Consumer Connectivity service. type: oauth2