openapi: 3.0.3 info: title: "SaaS: Subscriptions API" description: API for interacting with SaaS Subscriptions. version: 1.0.0 contact: name: Snow Software, Inc. url: https://www.snowsoftware.com servers: - url: https://{region}.snowsoftware.io variables: region: enum: - westeurope - australiasoutheast - eastus2 - uksouth default: westeurope paths: /api/saas/consolidated-view/v1/subscriptions/{subscriptionId}/insights/{insightRuleId}/users: get: summary: Get subscription insight users description: Returns a collection of users for a subscription insight. operationId: getSaasConsolidatedViewV1ApplicationsIdInsightsInsightruleidUsers responses: "200": description: "OK: Your request succeeded." content: application/json: schema: $ref: "#/components/schemas/SubscriptionInsightUsersResponse" "400": $ref: "#/components/responses/400" "404": $ref: "#/components/responses/404" "500": $ref: "#/components/responses/500" parameters: - name: subscriptionId in: path required: true schema: type: string example: a7a75b83-2690-4cc9-b652-a0fbe93dba4a description: The unique ID of the subscription. - name: insightRuleId in: path required: true schema: type: string example: 577ee610-95f2-4883-abaa-d702e73c3a10 description: The unique ID of the insight. - $ref: "#/components/parameters/PageSize" - $ref: "#/components/parameters/PageNumber" - name: filter description: "For more information on the available operators and which data types those operators work on, see [Filter API call results](https://docs.snowsoftware.io/snow-atlas-api/resources/get-started-with-apis/api-conventions#filter-api-call-results)." in: query schema: type: string example: ?filter=field1 -eq "abc" - name: sort description: "For more information on sorting capability and examples, see [Sort API call results](https://docs.snowsoftware.io/snow-atlas-api/resources/get-started-with-apis/api-conventions#sort-api-call-results)." in: query schema: type: string example: ?sort=field1:asc security: - bearerAuth: - saas.consolidation.view.r - bearerAuth: - saas.consolidation.view.crud tags: - Subscriptions /api/saas/consolidated-view/v1/subscriptions/{subscriptionId}/users/{userIds}: delete: summary: Delete subscription users description: Removes the given one or more assigned users from a subscription. operationId: deleteSaasConsolidatedViewV1UsersDelete parameters: - name: subscriptionId in: path required: true schema: type: string example: a7a75b83-2690-4cc9-b652-a0fbe93dba4a description: The unique ID of the subscription. - name: userIds in: path required: true description: The unique ID of the of the subscriptions. schema: type: array example: [ d69809c5-e4c0-4d22-be9f-f541f6a265ee, f90eeb4b-614b-432c-b506-4203a2db60c8, ] responses: "204": $ref: "#/components/responses/204" "400": $ref: "#/components/responses/400" "404": $ref: "#/components/responses/404" "500": $ref: "#/components/responses/500" security: - bearerAuth: - saas.consolidation.view.r - bearerAuth: - saas.consolidation.view.crud tags: - Subscriptions /api/saas/consolidated-view/v1/subscriptions/{subscriptionId}/users: get: summary: Get subscription users description: Returns a collection of users assigned to a subscription. operationId: getSubscriptionUsers parameters: - name: subscriptionId in: path required: true schema: type: string example: a7a75b83-2690-4cc9-b652-a0fbe93dba4a description: The unique ID of the user. - $ref: "#/components/parameters/PageSize" - $ref: "#/components/parameters/PageNumber" responses: "200": description: "OK: Your request succeeded." content: application/json: schema: properties: pagination: $ref: "#/components/schemas/Pagination" items: type: array description: A collection of subscription users. items: $ref: "#/components/schemas/User" required: - items - pagination "400": $ref: "#/components/responses/400" "404": $ref: "#/components/responses/404" "500": $ref: "#/components/responses/500" security: - bearerAuth: - saas.consolidation.view.r - bearerAuth: - saas.consolidation.view.crud tags: - Subscriptions tags: - name: Subscriptions components: parameters: PageSize: name: page_size in: query required: false description: The maximum number of items in the response. schema: type: integer default: 100 maximum: 1000 PageNumber: name: page_number in: query required: false description: The page number. schema: type: integer format: int64 default: 1 responses: "204": description: "No Content: Your request succeeded, but the response message was empty." "400": description: "Bad Request: Your request is invalid or improperly formed. Consequently, the API server could not understand your request." content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" example: error: code: 400 message: Filter field name needs to be formatted as a string. "404": description: "Not Found: The operation you requested failed because a resource associated with your request could not be found." content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" example: error: code: 404 message: Resource with ID '32aeda0a-80dc-475a-907f-2d250a3a8614' not found. "500": description: "Internal Server Error: Your request failed due to an internal error." content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" example: error: code: 500 message: The service encountered an unexpected condition that prevented it from fulfilling the request. schemas: ErrorResponse: type: object required: - error properties: error: description: The error details. type: object required: - code - message properties: code: type: integer format: int32 description: The HTTP status code. message: type: string description: The error message. User: title: User description: "A discovered user in your SaaS estate." type: object properties: country: description: The country of the user. example: Japan type: string createdDate: description: The date the user was created. example: "2024-05-25T00:00:00Z" type: string format: date-time department: description: The department of the user. example: Engineering type: string discoveryTypes: description: The unique IDs of the discovery source types where the user was detected. For information on IDs, see [Discovery sources](https://docs.snowsoftware.io/snow-atlas/user-documentation/saas/saas-discovery#discovery-sources).. example: [1, 2] type: array items: type: integer format: int32 displayName: description: The display name of the user. example: John Doe type: string email: description: The email address of the user. example: john.doe@organization.com type: string id: description: The unique ID of the user. example: 2f86b198-04f3-4770-ad08-b32518206da0 type: string isEnabled: description: "```true``` if the enabled state of the user in the discovery source is true.; otherwise, ```false```." example: true type: boolean isInReview: description: "```true``` if user has been marked as one to be analyzed further, or as a reminder for taking action on their subscriptions; otherwise, ```false```." example: true type: boolean isOnline: description: "```true``` if user has been marked as a SaaS user; who does not have a device that is inventoried in your organization. This is common for, for example, consultants and other temporary staff; otherwise, ```false```." example: true type: boolean isQualified: description: "```true``` if has been marked to be included in Snow's services which incur a cost; otherwise, ```false```." example: true type: boolean lastActive: description: The date of last user activity in relevant applications. example: "2024-06-28T00:00:00Z" type: string format: date-time licenseCount: description: The number of subscription types assigned to the user. example: 5 type: integer format: int32 potentialSavings: description: The monthly subscription costs for users who are inactive or have no activity. example: 500.0 type: number format: double status: description: The activity status of the user in relevant applications. example: "Active" type: string userCostPerMonth: description: The monthly cost of the user's subscription entitlements. example: 1000.0 type: number format: double username: description: The username of the user. example: john.doe_1@org.com type: string required: - id - country - discoveryTypes - isInReview - isQualified - status - email - department - createdDate - lastActive - userCostPerMonth - potentialSavings - displayName - username - licenseCount - isOnline SubscriptionInsightsUserDetail: title: SubscriptionInsightsUserDetail type: object properties: lastActive: description: The date of last user activity in relevant subscription or application. type: string format: date-time subscriptionId: description: The unique ID of the subscription. type: string example: 1519f3e3-7e5a-466b-8a86-63ed2776f819 subscriptionName: description: The name of the subscription. type: string example: Microsoft 365 E5 applicationId: description: The unique ID of the application. type: string example: 3519f3f3-7e5a-e66b-8a86-63ed2776f618 applicationName: description: The name of the application. type: string example: Microsoft Power BI required: - subscriptionId - subscriptionName - lastActive UserSubscription: title: UserSubscription type: object properties: applicationId: description: The unique ID of the application for which the subscription is purchased. example: def96bf0-bfd1-4bf9-8b1c-aa78a32bc0ed type: string applicationName: description: The application for which the subscription is purchased. example: Microsoft Copilot type: string discoverySource: description: The discovery source that detected the item. example: "O365 Connector" type: string discoveryType: description: The unique ID of the discovery source type where the user was detected. For information on IDs, see [Discovery sources](https://docs.snowsoftware.io/snow-atlas/user-documentation/saas/saas-discovery#discovery-sources). example: 0 type: integer format: int32 firstDiscovered: description: The time the item was first detected by a discovery source. example: "2024-07-17T08:21:17.359Z" type: string format: date-time id: description: The unique ID of the subscription. example: ac2c7870-6457-4a99-bafb-467eaf5de8e4 type: string lastActivity: description: The date of the last user activity in relevant applications. example: "2024-06-28T00:00:00Z" type: string format: date-time name: description: The name of the subscription type. example: "Copilot" type: string potentialSavings: description: The monthly subscription costs for users who are inactive or have no activity. example: 100.00 type: number format: double totalCostPerMonth: description: The monthly cost for the subscription. example: 100.00 type: number format: double vendor: description: The vendor of the application for which the subscription is purchased. example: "Microsoft Corporation" type: string vendorId: description: The unique ID of the vendor. example: 8cab5d46-18fd-462f-9ae8-6cac8ba12054 type: string required: - totalCostPerMonth - applicationId - applicationName - id - discoveryType - lastActivity - vendorId - vendor - name - activity - discoverySource - firstDiscovered - potentialSavings SubscriptionInsightUsersResponse: title: SubscriptionInsightUsersResponse description: A collection of users that relate to a subscription insight. required: - items - pagination type: object properties: items: description: A collection of the requested paginated items. type: array items: allOf: - $ref: "#/components/schemas/User" - properties: details: type: array description: "A collection of the user's subscriptions that relate to the insight." items: $ref: "#/components/schemas/SubscriptionInsightsUserDetail" required: - details pagination: $ref: "#/components/schemas/Pagination" Pagination: type: object description: The pagination details. required: - page_size - page_number properties: page_size: type: integer description: The page size you requested. example: 100 page_number: type: integer format: int64 description: The page number you requested. example: 1 total_pages: type: integer format: int64 description: The total number of pages. example: 1 total_items: type: integer format: int64 description: The total number of items. example: 1 securitySchemes: bearerAuth: type: http scheme: bearer bearerFormat: JWT