Cloud APIs
...
BSN.Cloud Main APIs
Main API version 2022/06
Device Subscriptions Endpoints (2022/06)
7min
these endpoints allow users to manage device subscriptions on a network base url for these endpoints https //api bsn cloud/2022/06/rest/subscriptions get / returns a list of device subscriptions required scope token bsn api main subscriptions retrieve query string parameters filter string string optional optional a search filtering and sorting expressions in the main api docid 3l0afyd3xooe ytvfk2vs for narrowing the result set sort string string optional optional an expression for sorting the search results the sort expression specifies the entry used for sorting and the ascending/descending (asc/desc) sorting order (see filtering and sorting expressions in the main api docid 3l0afyd3xooe ytvfk2vs for more information) marker string string optional optional a value specifying which page to retrieve this value is useful if the istruncated entry in the response body of the previous get call indicates that the number of device subscription instances exceeds the pagesize this parameter is only required if you need more elements in the paged list than the pagesize (100) pagesize int int optional optional the maximum number of device subscription instances that can be contained in the response body this defaults to the maximum allowed page size (100) request example the example request parameters and headers are set as follows marker value is set to the \[pagedlist] \[nextmarker] property value from the previous bsn cloud api response pagesize is set to 1 filter is set to \[device] is null and \[status] is in ('active', 'suspending') sort is set to \[creationdate] desc get /2022/06/rest/subscriptions/?marker=ndi0nty0ldqyndu2na%3d%3d\&pagesize=1\&filter=%5bdevice%5d%20is%20null%20and%20%5bstatus%5d%20is%20in%20%28%27active%27%2c%20%27suspending%27%29\&sort=%5bcreationdate%5d%20desc http/1 1 host api bsn cloud connection keep alive authorization bearer {{useraccesstoken}} accept application/json, application/vnd bsn error+json accept encoding gzip,deflate success response body 200 200 returns a paged list entity (2022/06) docid\ pwwr0ln3 binngl mr3st of player subscription entities on a network this will return not more than 100 entities along with the information necessary to return any other remaining pages example { "items" \[ { "id" 424574, "device" null, "type" "commercial", "activityperiod" "365 00 00 00", "status" "active", "creationdate" "2023 06 02t07 02 52 99z", "lastmodifieddate" "2023 06 02t07 02 52 99z", "activationdate" "2023 06 02t07 02 52 99z", "suspensiondate" null, "expirationdate" null }], "totalitemcount" 20, "matchingitemcount" 9, "pagesize" 1, "nextmarker" "mjaymy0wni0wmlqwnzowmjo1mi45otbaldqyndu3na==", "prevmarker" "mjaymy0wni0wmlqwnzowmjo1mi45otbaldqyndu36h78", "istruncated" true, "sortexpression" "\[creationdate] desc", "filterexpression" "\[device] is null and \[status] is in ( 'active' , 'suspending' )" } failure response 300 300 the requested representation could not be returned because it is ambiguous (there are multiple requested representations) 400 400 the request is malformed and therefore invalid 401 401 the access token is invalid or not specified 403 403 the supplied access token, though valid, doesn't provide access to this method 406 406 the server cannot return the data representation that you requested (as specified in the "accept" header) 5xx 5xx any 500 code is an internal server error get /count/ retrieves the number of subscription instances on the network matching the specified filter criteria if no filter is included, this call returns the total number of subscription instances on the network required scope token bsn api main subscriptions retrieve query string parameter filter string string optional optional an filtering and sorting expressions in the main api docid 3l0afyd3xooe ytvfk2vs for filtering search results the default value is null request example the example request parameters and headers are set as follows filter is set to \[id] is greater than 0 and \[status] is in ('active', 'suspending') get /2022/06/rest/subscriptions/count/?pagesize=0\&filter=%5bid%5d%20is%20greater%20than%200%20and%20%5bstatus%5d%20is%20in%20%28%27active%27%2c%20%27suspending%27%29 http/1 1 host api bsn cloud connection keep alive authorization bearer {{useraccesstoken}} accept application/json, application/vnd bsn error+json accept encoding gzip,deflate success response body 200 200 the subscription instance count is returned as an integer value failure response 300 300 the requested representation could not be returned because it is ambiguous (there are multiple requested representations) 400 400 the request is malformed and therefore invalid 401 401 the access token is invalid or not specified 403 403 the supplied access token, though valid, doesn't provide access to this method 406 406 the server cannot return the data representation that you requested (as specified in the "accept" header) 5xx 5xx any 500 code is an internal server error get /operations/ returns operational permissions granted to roles for specific business operations required scope token bsn api main operations retrieve request example the example request parameters and headers are set as follows get /2022/06/rest/subscriptions/operations/ http/1 1 host api bsn cloud connection keep alive authorization bearer {{useraccesstoken}} accept application/json, application/vnd bsn error+json accept encoding gzip,deflate success response body 200 200 returns the business operations entity (2022/06) docid\ ei98k7oul6z5i 5b d6js example expand { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" \[ { "uid" "d6416c44 747e 7e24 f549 5a57525e046d", "singularname" "view subscription", "pluralname" "view subscriptions", "fullname" "device subscription (full control) view subscriptions", "targetentity" "subscription", "appliance" "instance, collection", "parent" { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" null, "permissions" null }, "descendants" \[], "permissions" \[ { "entityid" null, "operationuid" "d6416c44 747e 7e24 f549 5a57525e046d", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" false, "isallowed" true, "creationdate" "2020 03 05t16 59 06 767z" }, { "entityid" null, "operationuid" "d6416c44 747e 7e24 f549 5a57525e046d", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" false, "isallowed" true, "creationdate" "2020 03 05t16 59 07 503z" }, { "entityid" null, "operationuid" "d6416c44 747e 7e24 f549 5a57525e046d", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "d6416c44 747e 7e24 f549 5a57525e046d", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "d6416c44 747e 7e24 f549 5a57525e046d", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "d6416c44 747e 7e24 f549 5a57525e046d", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" } ] }, { "uid" "398bd8f9 8950 4735 97f8 50bf8c8b5759", "singularname" "export subscriptions", "pluralname" "export subscriptions", "fullname" "device subscription (full control) export subscriptions", "targetentity" "subscription", "appliance" "instance, collection", "parent" { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" null, "permissions" null }, "descendants" \[], "permissions" \[ { "entityid" null, "operationuid" "398bd8f9 8950 4735 97f8 50bf8c8b5759", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" false, "isallowed" true, "creationdate" "2020 03 05t16 59 07 517z" }, { "entityid" null, "operationuid" "398bd8f9 8950 4735 97f8 50bf8c8b5759", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "398bd8f9 8950 4735 97f8 50bf8c8b5759", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "398bd8f9 8950 4735 97f8 50bf8c8b5759", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "398bd8f9 8950 4735 97f8 50bf8c8b5759", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" }, { "entityid" null, "operationuid" "398bd8f9 8950 4735 97f8 50bf8c8b5759", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 753z" } ] }, { "uid" "1d8a9fc5 5958 7fe4 959b 447491382e87", "singularname" "view subscription invoice", "pluralname" "view subscription invoices", "fullname" "device subscription (full control) view subscription invoices", "targetentity" "subscriptioninvoice", "appliance" "instance, collection", "parent" { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" null, "permissions" null }, "descendants" \[], "permissions" \[ { "entityid" null, "operationuid" "1d8a9fc5 5958 7fe4 959b 447491382e87", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "1d8a9fc5 5958 7fe4 959b 447491382e87", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "1d8a9fc5 5958 7fe4 959b 447491382e87", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "1d8a9fc5 5958 7fe4 959b 447491382e87", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" }, { "entityid" null, "operationuid" "1d8a9fc5 5958 7fe4 959b 447491382e87", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 753z" }, { "entityid" null, "operationuid" "1d8a9fc5 5958 7fe4 959b 447491382e87", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 07 493z" } ] }, { "uid" "b2edb137 9e21 b444 5913 d3ef4ec7ef0c", "singularname" "view traffic invoice", "pluralname" "view traffic invoices", "fullname" "device subscription (full control) view traffic invoices", "targetentity" "trafficinvoice", "appliance" "instance, collection", "parent" { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" null, "permissions" null }, "descendants" \[], "permissions" \[ { "entityid" null, "operationuid" "b2edb137 9e21 b444 5913 d3ef4ec7ef0c", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "b2edb137 9e21 b444 5913 d3ef4ec7ef0c", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "b2edb137 9e21 b444 5913 d3ef4ec7ef0c", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "b2edb137 9e21 b444 5913 d3ef4ec7ef0c", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" }, { "entityid" null, "operationuid" "b2edb137 9e21 b444 5913 d3ef4ec7ef0c", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 753z" }, { "entityid" null, "operationuid" "b2edb137 9e21 b444 5913 d3ef4ec7ef0c", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 07 493z" } ] }, { "uid" "083dc302 4ac3 4e3a be2d be0b44c9a4fe", "singularname" "export subscription invoice", "pluralname" "export subscription invoices", "fullname" "device subscription (full control) export subscription invoices", "targetentity" "subscriptioninvoice", "appliance" "collection", "parent" { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" null, "permissions" null }, "descendants" \[], "permissions" \[ { "entityid" null, "operationuid" "083dc302 4ac3 4e3a be2d be0b44c9a4fe", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "083dc302 4ac3 4e3a be2d be0b44c9a4fe", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "083dc302 4ac3 4e3a be2d be0b44c9a4fe", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "083dc302 4ac3 4e3a be2d be0b44c9a4fe", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" }, { "entityid" null, "operationuid" "083dc302 4ac3 4e3a be2d be0b44c9a4fe", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 753z" }, { "entityid" null, "operationuid" "083dc302 4ac3 4e3a be2d be0b44c9a4fe", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 07 493z" } ] }, { "uid" "9a99bf40 9791 4114 b90a 2c86d04a5254", "singularname" "export traffic invoice", "pluralname" "export traffic invoices", "fullname" "device subscription (full control) export traffic invoices", "targetentity" "trafficinvoice", "appliance" "collection", "parent" { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" null, "permissions" null }, "descendants" \[], "permissions" \[ { "entityid" null, "operationuid" "9a99bf40 9791 4114 b90a 2c86d04a5254", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "9a99bf40 9791 4114 b90a 2c86d04a5254", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "9a99bf40 9791 4114 b90a 2c86d04a5254", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "9a99bf40 9791 4114 b90a 2c86d04a5254", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" }, { "entityid" null, "operationuid" "9a99bf40 9791 4114 b90a 2c86d04a5254", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 753z" }, { "entityid" null, "operationuid" "9a99bf40 9791 4114 b90a 2c86d04a5254", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 07 493z" } ] }, { "uid" "a3f0679f a23f 4130 bb73 84e1a1f0f9da", "singularname" "update subscription", "pluralname" "update subscription", "fullname" "device subscription (full control) update subscription", "targetentity" "subscription", "appliance" "instance, collection", "parent" { "uid" "616d956d 9a74 f674 61a9 3ab02f028352", "singularname" "full control", "pluralname" "device subscription (full control)", "fullname" "device subscription (full control)", "targetentity" "subscription", "appliance" "instance, collection", "parent" null, "descendants" null, "permissions" null }, "descendants" \[], "permissions" \[ { "entityid" null, "operationuid" "a3f0679f a23f 4130 bb73 84e1a1f0f9da", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "a3f0679f a23f 4130 bb73 84e1a1f0f9da", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" true, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "a3f0679f a23f 4130 bb73 84e1a1f0f9da", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "a3f0679f a23f 4130 bb73 84e1a1f0f9da", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" }, { "entityid" null, "operationuid" "a3f0679f a23f 4130 bb73 84e1a1f0f9da", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 06 753z" }, { "entityid" null, "operationuid" "a3f0679f a23f 4130 bb73 84e1a1f0f9da", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" true, "isallowed" false, "creationdate" "2020 03 05t16 59 07 493z" } ] } ], "permissions" \[ { "entityid" null, "operationuid" "616d956d 9a74 f674 61a9 3ab02f028352", "principal" { "name" "administrators", "iscustom" false, "type" "role", "id" 1 }, "isfixed" true, "isinherited" false, "isallowed" true, "creationdate" "2020 03 05t16 59 05 18z" }, { "entityid" null, "operationuid" "616d956d 9a74 f674 61a9 3ab02f028352", "principal" { "name" "general managers", "iscustom" false, "type" "role", "id" 2 }, "isfixed" true, "isinherited" false, "isallowed" true, "creationdate" "2020 03 05t16 59 05 437z" }, { "entityid" null, "operationuid" "616d956d 9a74 f674 61a9 3ab02f028352", "principal" { "name" "creators", "iscustom" false, "type" "role", "id" 3 }, "isfixed" true, "isinherited" false, "isallowed" false, "creationdate" "2020 03 05t16 59 05 747z" }, { "entityid" null, "operationuid" "616d956d 9a74 f674 61a9 3ab02f028352", "principal" { "name" "publishers", "iscustom" false, "type" "role", "id" 4 }, "isfixed" true, "isinherited" false, "isallowed" false, "creationdate" "2020 03 05t16 59 06 19z" }, { "entityid" null, "operationuid" "616d956d 9a74 f674 61a9 3ab02f028352", "principal" { "name" "network managers", "iscustom" false, "type" "role", "id" 5 }, "isfixed" true, "isinherited" false, "isallowed" false, "creationdate" "2020 03 05t16 59 06 753z" }, { "entityid" null, "operationuid" "616d956d 9a74 f674 61a9 3ab02f028352", "principal" { "name" "viewers", "iscustom" false, "type" "role", "id" 6 }, "isfixed" true, "isinherited" false, "isallowed" false, "creationdate" "2020 03 05t16 59 07 493z" } ] } failure response 300 300 the requested representation could not be returned because it is ambiguous (there are multiple requested representations) 400 400 the request is malformed and therefore invalid 401 401 the access token is invalid or not specified 403 403 the supplied access token, though valid, doesn't provide access to this method 406 406 the server cannot return the data representation that you requested (as specified in the "accept" header) 5xx 5xx any 500 code is an internal server error