{
  "opencollection": "1.0.0",
  "info": {
    "name": "Cobot Subscription API",
    "version": "2.0"
  },
  "request": {
    "auth": {
      "type": "oauth2",
      "flow": "authorization_code",
      "authorizationUrl": "https://www.cobot.me/oauth/authorize",
      "accessTokenUrl": "https://www.cobot.me/oauth/access_token",
      "credentials": {
        "clientId": "{{clientId}}",
        "clientSecret": "{{clientSecret}}"
      }
    }
  },
  "items": [
    {
      "info": {
        "name": "Subscription",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "Preview",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.cobot.me/spaces/:spaceId/subscription_preview",
            "params": [
              {
                "name": "spaceId",
                "value": "",
                "type": "path",
                "description": "The id of the space."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "https://www.cobot.me/oauth/authorize",
              "accessTokenUrl": "https://www.cobot.me/oauth/access_token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Preview a space's subscription for the specified number of members and extras.\nSend a request without extras to get the available extra/tier ids.\n\n**Access**: The current user must be an admin of the space.\n"
        },
        {
          "info": {
            "name": "Current",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.cobot.me/spaces/:spaceId/subscription",
            "params": [
              {
                "name": "spaceId",
                "value": "",
                "type": "path",
                "description": "The id of the space."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "https://www.cobot.me/oauth/authorize",
              "accessTokenUrl": "https://www.cobot.me/oauth/access_token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Returns a space's current subscription, including member limit\nand any extras (subscribed and unsubscribed).\n\n**Access**: The current user must be an admin of the space.\n"
        },
        {
          "info": {
            "name": "Change",
            "type": "http"
          },
          "http": {
            "method": "PUT",
            "url": "https://api.cobot.me/spaces/:spaceId/subscription",
            "params": [
              {
                "name": "spaceId",
                "value": "",
                "type": "path",
                "description": "The id of the space."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "https://www.cobot.me/oauth/authorize",
              "accessTokenUrl": "https://www.cobot.me/oauth/access_token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Update or change a space's subscription.\n\nTo update the extras but not change the subscription, pass the id of a space's current\nsubscription as the `chosenSubscription` relationship.\n\nTo change the subscriptipn to one returned by the list subscriptions\nendpoint, pass the id of one of these subscriptions.\n\nIf the space had a previous subscription, custom extras\n(type `subscriptionExtras`) are kept automatically and cannot be modified.\n\nOther extras are dropped and extras whose id is passed in th"
        },
        {
          "info": {
            "name": "List",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.cobot.me/spaces/:spaceId/subscriptions",
            "params": [
              {
                "name": "spaceId",
                "value": "",
                "type": "path",
                "description": "The id of the space."
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "https://www.cobot.me/oauth/authorize",
              "accessTokenUrl": "https://www.cobot.me/oauth/access_token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Returns all subscriptions available to spaces, including member limit,\nwhether they are available and any extras.\n\n**Access**: The current user must be an admin of the space.\n"
        }
      ]
    }
  ],
  "bundled": true
}