API Manual BaiBOSS 8.3
API Manual BaiBOSS 8.3
Programming Guide
BaiBOSS 8.3
February 2023
Version 2.0
BOSS API Manual
Copyright Notice
Baicells Technologies copyrights the information in this document. No part of this document may be
reproduced in any form or means without the prior written consent of Baicells Technologies. The
Baicells logo is a proprietary trademark of Baicells Technologies. Other trademarks mentioned in this
document belong to their owners.
Disclaimer
All products, services, and features bought from Baicells Technologies are subject to the constraints
of the company's business contract and terms. All or part of the products, services, or features
described in this document might not be your specific Baicells network. Unless stated in the contract,
Baicells Technologies does not make any explicit or default statement or guarantee about the
contents of this document.
Unless stated otherwise, this document serves only as a user guide, and all descriptions/
information/ suggestions mean no guarantee, neither explicit nor implicit.
The information in this document is subject to change at any time without notice. For more
information, please consult with a Baicells technical engineer or the support team. Refer to the
“Contact Us” section.
Revision Record
Date Version Description SMEs/Contributors Editor
21-Feb-2023 V2.0 Updated for BaiBOSS 8.3, v11 HQ version: Yunfeng Jiang Jocelyn Watson
• Query Full List of Subscriber IDs
• Query Full list of IMSIs
18-May-2020 V1.9 Review comments Yunfeng Jiang, Sharon Redfoot
V1.8 Updated for BOSS v6.0 ZhangGuihua
2-Mar-2020 V1.7 New logo & colors Chris Culver Sharon Redfoot
25-Apr-2019 V1.6 Notated local BOSS environment sections Jesse Raasch Sharon Redfoot
20-Mar-2019 V1.5 Preliminary - updated for China V5 ZhangGuihua Sharon Redfoot
V1.4 BaiBOSS doc Jesse Raasch
11-Dec-2017 V1.3 Checked UE, eNB terms Bob Stone Sharon Redfoot
16-Nov-2017 V1.2 Added N.A. URL Cameron Kilton Sharon Redfoot
5-Oct-2017 V1.1 Edit for North American customers and Jesse Raasch, Rick Sharon Redfoot
partners Harnish, Cameron
Kilton
Sept 2017 V1.0 New Simon, Yang Yanan
ii
BOSS API Manual
Resources
• Documentation - Baicells product datasheets, technical manuals, and a list of acronyms and
abbreviations can be found at Baicells.com > Resources > Documents.
• Support - Open a support ticket, process an RMA, and the Support Forum is at
Baicells.com > Support.
Contact Us
Baicells Technologies
5700 Tennyson Pkwy, #300, Plano, TX 75024, USA
Phone: +1-888-502-5585
Email: [email protected] for North America or [email protected] for all other regions
Website: baicells.com
iii
BOSS API Manual
Table of Contents
1. API OVERVIEW......................................................................................................................................... 1
2. API LIST.................................................................................................................................................... 3
3. APPENDIX: ............................................................................................................................................. 58
v
BOSS API Manual
1. API Overview
The Baicells Application Programming Interface (API) is a Representational State Transfer, or RESTful,
API that accepts and receives JavaScript Object Notations (JSON). The API utilizes common Hypertext
Transfer Protocol (HTTP) methods such as GET, POST, PATCH, and DELETE.
The Baicells API header is added to the basic HTTP authentication mode via HTTP requests, provided
there is prior agreement with partners on a common user name and password. Permissions for the
API are inherited from the user account.
When submitting a request using basic HTTP authentication, you must also include a header for
“Content-Type” that specifies “application/json”; a header for “cloud_key” that specifies the
operator’s cloud_key; and a header for “Authorization” that specifies the encoded value of
“username:password” through the base64.
Table 1-1 provides the result_code list for when an operation fails.
Table 1-1: Result_Code List
Code Message
4001 sub_idConflict
4011 Subscribers do not exist or do not bind imsi and service plan
1
BOSS API Manual
Code Message
4704 Query usage by hour size. Time interval should not exceed 31 days.
4705 Query CDR detail. Time interval should not exceed 7 days.
2
BOSS API Manual
Code Message
Code Message
2. API List
North American CloudCore API URL: http://baiboss.cloudapp.net:47081/baicellsapi"
Category Functions Comments
System setting Set redirect url and allow access to IP Not supported
Query subscriber
Create subscriber
Bind imsi
Unbind imsi
Deactivate subscriber
3
BOSS API Manual
Modify subscriber
Delete subscriber
Example request:
POST /baicellsapi/customers/query HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"imsi": "460010000000001"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
available boolean true:the imsi can be user
false:the imsi cannot be user
sub_id String The internal ID of the subscriber
sub_name String The name of the subscriber
id_num String The ID number of the subscriber
phone_number String The phone number of the subscriber
4
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": “200”,
"available": false,
"sub_id": "20161201",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
"service_plan_id": "2016001",
"sub_status": "0",
"svc_state": "0"
} or
"session_id": "2016123456",
"result_code": “200”,
"available": true
5
BOSS API Manual
param
Field Data Type Length Description
session_id String Business serial number
sub_id String 20 The internal ID of the subscriber
sub_name String 60 The name of the subscriber
id_num String 20 The ID number of the subscriber
phone_number String 20 The phone number of the subscriber
email String 60 The email of the subscriber
address String 200 The address of the subscriber
Example request:
POST /baicellsapi/customers/create HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "20161201",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response - If the success return status code is 200, it is applicable to all interfaces:
HTTP/1.1 200 OK
Content-Type: application/json
{
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
6
BOSS API Manual
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:4000/4001
message String Message: sub_id conflict
Example response - If the fail return status code is 422, it is applicable to all interfaces:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4001",
Example request:
POST /baicellsapi/customers/bindservice HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "20161201",
"service_plan_id": "2016001"
7
BOSS API Manual
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code":"200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:4000/4002/4200/4202
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002"
8
BOSS API Manual
Example request:
POST /baicellsapi/customers/bindimsi HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "20161201",
"imsi": "460010000000001"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4002/4300/4301/4302
message String Message
Example response
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4301"
9
BOSS API Manual
Example request:
POST /baicellsapi/customers/unbindimsi HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "20161201"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4002/5001
message String Message
10
BOSS API Manual
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002",
Example request:
POST /baicellsapi/customers /activate HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"sub_id": "20161201"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
11
BOSS API Manual
}
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4002/4003/4004/5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002",
Example request:
POST /baicellsapi/customers/deactivate HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"sub_id": "20161201"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
12
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code":"200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4002/5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002",
param
Field Data Type Description
session_id String Business serial number
sub_id String The internal ID of the subscriber
new_service_plan_id String The new service plan id
Example request:
POST /baicellsapi/customers/update HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
13
BOSS API Manual
"sub_id": "20161201",
"new_service_plan_id": "2016001"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
{
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
}
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4002/4202/5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002",
14
BOSS API Manual
param
Field Data Type Description
session_id String Business serial number
sub_id String The internal ID of the subscriber
uplink int Uplink speed.Unit:MB(maximum:1000MB)
downlink int Downlink speed.Unit:MB(maximum:1000MB
Example request:
POST /baicellsapi/customers/updateuplink HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"sub_id": "20161201",
"downlink": 5,
"uplink": 5
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:
4000/4002/4401/4402/4403/4404/5001
message String Message
15
BOSS API Manual
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002",
param
Field Data Type Description
session_id String Business serial number
sub_id String The internal ID of the subscriber
Example request:
POST /baicellsapi/customers/bulkactivate HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"data":[
"20161201",
"20161202",
"20161203",
"20161204"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
16
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "5001",
Example request:
POST /baicellsapi/customers/bulkdeactivate HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"data":[
17
BOSS API Manual
"20161201",
"20161202",
"20161203",
"20161204"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "5001",
18
BOSS API Manual
Example request:
POST /baicellsapi/customers/querybyid HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "20161201"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
imsi String imsi
sub_id String The internal ID of the subscriber
sub_name String The name of the subscriber
id_num String The ID number of the subscriber
phone_number String The phone of the subscriber
email String The email of the subscriber
address String The address of the subscriber
service_plan_id String The subscriber bound service plan
sub_status String The status of the subscriber:
“0”:active
“1”:deactive
up_rate String Up speed of bind service plan
down_rate String Down speed of bind service plan
apn_info_list JSON String Bind apn ip information
svc_state String The status of redirection
“0”:no redirection
“1”:direction
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
19
BOSS API Manual
{
"session_id": "2016123456",
“result_code”: "200",
"imsi": "460010000000001",
"sub_id": "20161201",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
"service_plan_id": "2016001",
"sub_status": "0",
"up_rate":"5",
"down_rate":"10",
"apn_info_list":[{"apn_name":"apn1","apn_ambr_ul":4,"apn_ambr_dl":8,
"ipv4":"192.168.1.10"}],
"svc_state":"0"
NOTE: Not supported in North America CloudCore, but is supported in a Local OMC+BOSS
environment
Detail:
POST http://ipaddr:port/baicellsapi/customers/bindapnip
param
Field Data Type Length Description
session_id String Business serial number
sub_id String The internal ID of the subscriber
apn_name String 100 Apn name
apn_ambr_ul int 7 apn_ambr_ul
apn_ambr_dl int 7 apn_ambr_dl
type_of_context String 1 Is default APN: 0-normal,1-default
static_ip_setting String 1 Bind the static IP: 0-no, 1-yes
ip_addr String 40 IP address
NOTE: If you do not set a static IP, this parameter should
be set to empty or you should delete the parameter.
Example request:
20
BOSS API Manual
POST /baicellsapi/customers/bindapnip HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "2017062201",
"apn_name": "apn1",
"apn_ambr_ul": 4,
"apn_ambr_dl": 8,
"type_of_context": 0,
"static_ip_setting": 1
"ip_addr": "192.168.1.10"
"session_id":"2016123456",
"sub_id": "2017062201",
"apn_name": "apn1",
"apn_ambr_ul": "4",
"apn_ambr_dl": "8"
"type_of_context": 0,
"static_ip_setting": 0
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "200",
"message": "Success"
21
BOSS API Manual
}
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4108/4109/4110/4111/4112/4113
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4108"
NOTE: Not supported in North America CloudCore, but is supported in a Local OMC+BOSS
environment
Detail:
POST http://ipaddr:port/baicellsapi/customers/removeapnip
param
Field Data Type Description
session_id String Business serial number
sub_id String The internal ID of the subscriber
apn_name String Apn name
apn_ambr_ul String apn_ambr_ul
apn_ambr_dl String apn_ambr_dl
Example request:
POST /baicellsapi/customers/removeapnip HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "2017062201",
"apn_name": "apn1",
"apn_ambr_ul": "4",
22
BOSS API Manual
"apn_ambr_dl": "8"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4108/
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4108"
23
BOSS API Manual
Example request:
POST /baicellsapi/customers/modify HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "20161201",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Subscriber does not exist
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
24
BOSS API Manual
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:4000/4002/5001
message String Message: sub_id conflict
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002",
param
Field Data Type Description
session_id String Business serial number
sub_id String The internal ID of the subscriber
Example request:
POST /baicellsapi/customers/delete HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"sub_id": "20161201"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Subscriber does not exist
25
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:4000/4002/5001
message String Message: sub_id conflict
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4002",
Example request:
26
BOSS API Manual
POST /baicellsapi/customers/create HTTP/1.1
Content-Type: application/json
{
"session_id":"2016123456",
"service_plan_id": "2016001",
"sub_list":[{
"sub_id": "20161201",
"sub_name": "test name",
"imsi":"860100011223344",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
"address": "test address"
},
{
"sub_id": "20161202",
"sub_name": "test name2",
"imsi":"860100011223355",
"id_num": "123457",
"phone_number": "1234567",
"email": "[email protected]",
"address": "test2 address"
}]
}
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
total int The total number of these operations
successful quantity Int The number of successes
unsuccessful quantity int The number of failures
success_list list The list of successes
fail_list list The list of failures
sub_id The internal ID of the subscriber
imsi The imsi of the subscriber
result_message Error message
27
BOSS API Manual
1) Parameters format error returned information:
Example response:
HTTP/1.1 422
"session_id": "198575111866",
"result_code": "4503",
HTTP/1.1 200
"session_id": "198575111866",
"total": 200,
"success_list": [
"sub_id": "66268756728",
"imsi": "601011010167723"
},
"sub_id": "66268751752",
"imsi": "601011010167747"
}...
],
"fail_list": [
"sub_id": "66268766671",
"imsi": "601011000166666",
"result_code": "4302",
{
28
BOSS API Manual
"sub_id": "66268866706aa",
"imsi": "601011000166701",
"result_code": "5001",
},
"sub_id": "66268866707",
"imsi": "601111000167702",
"result_code": "4001",
}...
Example request:
POST http://ipaddr:port/baicellsapi/customers/redirect HTTP/1.1
Content-Type: application/json
"session_id":"198575111866",
"sub_id_list":["AX1234","AX1235","AX1236"]
Success 200
Field Data Type Description
result_code String Successfully create a subscriber return code:200
message String Message:Success
29
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
result_code String Error return code: 4010/4011
message String Message:sub_id conflict
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"result_code": "4001",
Example request:
POST http://ipaddr:port/baicellsapi/customers/cancelredirect HTTP/1.1
Content-Type: application/json
"session_id":"198575111866",
"sub_id_list":["AX1234","AX1235","AX1236"]
Success 200
30
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
result_code String Error return code: 4010/4011
message String Message:sub_id conflict
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"result_code": "4001",
Example request:
POST /baicellsapi/customers/query HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"ip_addr": "192.169.1.1"
31
BOSS API Manual
}
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
available boolean true:the imsi can be user
false:the imsi can not be user
sub_id String The internal ID of the subscriber
sub_name String Thename of the subscriber
id_num String The ID number of the subscriber
phone_number String The phone of the subscriber
email String The email of the subscriber
address String The address of the subscriber
service_plan_id String The subscriber bound service plan
sub_status String The suatus of subscriber
“0”:active
“1”:deactive
svc_state String The status of redirection
“0”:no redirection
“1”:direction
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
"available": false,
"sub_id": "20161201",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
"service_plan_id": "2016001",
"sub_status": "0",
"svc_state": "0"
} or
32
BOSS API Manual
{
"session_id": "2016123456",
"result_code": “200”,
"available": true
Example request:
POST /baicellsapi/imsi/activate HTTP/1.1
Content-Type: application/json
"session_id": "201805180958",
"imsi": "600000000000081"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805180958",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
33
BOSS API Manual
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "201805180958",
"result_code": "4002",
Example request:
POST /baicellsapi/imsi/deactivate HTTP/1.1
Content-Type: application/json
"session_id": "201805181105",
"imsi": "600000000000081"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
34
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805181105",
"result_code":"200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4002/5001
message String Message
Example response
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "201805181105",
"result_code": "4002",
Example request:
POST http://ipaddr:port/baicellsapi/imsi/redirect HTTP/1.1
Content-Type: application/json
"session_id":"201805181511",
"imsi": "600000000000081"
35
BOSS API Manual
}
Success 200
Field Data Type Description
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805181105",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
result_code String Error return code: 4301
message String Message: imsi format error
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "201805181105",
"result_code": "4301",
36
BOSS API Manual
Example request:
POST http://ipaddr:port/baicellsapi/imsi/cancelredirect HTTP/1.1
Content-Type: application/json
"session_id":"201805181515",
"imsi": "600000000000081"
Success 200
Field Data Type Description
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id":"201805181515",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
result_code String Error return code: 4301
message String Message: imsi format error
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id":"201805181515",
"result_code": "4301",
37
BOSS API Manual
Example request:
POST /baicellsapi/imsi/updatespeed HTTP/1.1
Content-Type: application/json
"session_id": "201805181529",
"imsi": "600000000000081",
"downlink": 5,
"uplink": 5
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805181529",
"result_code": “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:
38
BOSS API Manual
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "201805181529",
"result_code": "4002",
Example request:
POST /baicellsapi/imsi/query HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"imsi": "600000000000081"
Success 200
Field Data Tpe Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
imsi String imsi
sub_id String The internal ID of the subscriber
sub_name String The name of the subscriber
id_num String The ID number of the subscriber
phone_number String The phone of the subscriber
email String The email of the subscriber
address String The address of the subscriber
39
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805181625",
“result_code”: "200",
"imsi": "600000000000081",
"sub_id": "20161201",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
"service_plan_id": "2016001",
"sub_status": "0",
"up_rate":"5",
"down_rate":"10",
"svc_state":"0",
"apn_info_list":[{"apn_name":"apn1","apn_ambr_ul":4,"apn_ambr_dl":8,
"ipv4":"192.168.1.10"}]
40
BOSS API Manual
Example request:
POST /baicellsapi/imsi/updateservice HTTP/1.1
Content-Type: application/json
"session_id": "201805221515",
"imsi": "600000000000081",
"new_service_plan_id": "2016001"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805221515",
"result_code": “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4000/4002/4202/5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "201805221515",
41
BOSS API Manual
"result_code": "4002",
Example request:
POST /baicellsapi/imsi/modify HTTP/1.1
Content-Type: application/json
"session_id":"201805221541",
"imsi": "600000000000081",
"id_num": "123456",
"phone_number": "123456",
"email": "[email protected]",
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Subscribers dose not exist
42
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805221541",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:4000/4002/5001
message String Message: sub_id conflict
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "201805221541",
"result_code": "4002",
Detail:
POST http://ipaddr:port/baicellsapi/imsi/delete
param
Field Data Type Description
session_id String Business serial number
imsi String The imsi of the subscriber
Example request:
POST /baicellsapi/imsi/delete HTTP/1.1
Content-Type: application/json
"session_id":"201805221455",
43
BOSS API Manual
"imsi": "600000000000081"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Subscribers dose not exist
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "201805221455",
"result_code": "200",
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:4000/4002/5001
message String Message: sub_id conflict
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "201805221455",
"result_code": "4002",
44
BOSS API Manual
HTTP/1.1 200 OK
Content-Type: application/json
"sub_list": [
"20220808001065",
"20220808001066"
param
Field Data Type Length Description
session_id String Business serial number
service_plan_id String 50 The internal ID of the service plan
service_plan_name String 100 The name of the service plan
uplink int 10 Uplink speed.Unit:MB
downlink int 10 Downlink speed.Unit:MB
comments String 100
Example request:
POST /products/create HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"service_plan_id": "2016001",
"service_plan_name": "testname",
"uplink": 5,
"downlink": 5,
"comments": "comments"
Success 200
45
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:
4200/4201/4401/4402/4403/4404/5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "5001",
46
BOSS API Manual
Example request:
POST /products/modify HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"service_plan_id": "2016001",
"service_plan_name": "testname",
"uplink": 5,
"downlink": 5,
"comments": "comments"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:
4200/4201/4401/4402/4403/4404/5001
message String Message
47
BOSS API Manual
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "5001",
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"service_plan_id":"T201611220001",
"service_plan_name":"1M",
"uplink":"1",
"downlink":"1",
"state":"0"
},
"service_plan_id":"T201611220002",
"service_plan_name":"1M",
"uplink":"1",
"downlink":"2",
"state":"0"
48
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"service_plan_id":"T201611220001",
"service_plan_name":"2M",
"uplink":"2",
"downlink":"2",
"state":"0"
},
"service_plan_id":"T201611220002",
"service_plan_name":"2M",
"uplink":"1",
"downlink":"2",
"state":"0"
49
BOSS API Manual
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"service_plan_id":"T201611220001",
"service_plan_name":"2M",
"uplink":"2",
"downlink":"2",
"state":"0"
},
"service_plan_id":"T201611220002",
"service_plan_name":"2M",
"uplink":"2",
"downlink":"2",
"state":"0"
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"service_plan_id":"T201611220001",
"service_plan_name":"1M",
"uplink":"1",
"downlink":"1",
50
BOSS API Manual
"state":"0"
},
"service_plan_id":"T201611220002",
"service_plan_name":"2M",
"uplink":"2",
"downlink":"2",
"state":"0"
param
Field Data Type Description
session_id String Business serial number
service_plan_id String The internal ID of the service plan
Example request:
POST /products/modify HTTP/1.1
Content-Type: application/json
"session_id": "2016123456",
"service_plan_id": "2016001"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully return code:200
message String Message:Success
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
51
BOSS API Manual
"session_id": "2016123456",
“result_code”: “200”,
"message": "Success"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code:
4200/4202/4207/5001
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "5001",
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"service_plan_id":"T201611220001",
"service_plan_name":"2M",
"uplink":"2",
"downlink":"2",
"state":"0"
52
BOSS API Manual
}
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"imsi_list": [
"454120000000065",
"454120000000066"
NOTE: Not supported in North America CloudCore, but is supported in a Local OMC+BOSS
environment
Detail:
POST http://ipaddr:port/baicellsapi/usage/querybyhour
param
Field Data Type Required Description
session_id String Yes Business serial number
imsi String No If the imsi is not empty query the specified
IMSI’s usage. If imsi is empty query all IMSI’s
usage.
begin_time String Yes Time interval of queries, Format:yyyy-MM-dd
hh:mm:ss
The maximum time interval is 31 days.
53
BOSS API Manual
Example request:
POST /baicellsapi/usage/querybyhour HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"imsi":"600000000000001",
"begin_time":"2018-11-22 08:00:00",
"end_time":"2018-11-22 12:00:00"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
usage_infos JSONArray Return data list
imsi String imsi
total_usage String Unit (KB)
up_usage String Unit (KB)
down_usage String Unit (KB)
usage_time String Time of Statistical usage. For example:(2018-11-22
10:00:00) means the usage data from 9 o'clock to 10
o'clock.
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "200",
"usage_infos":[
"imsi":"600000000000001",
"total_usage":"204800",
"up_usage":"1000",
"down_usage":"203800",
54
BOSS API Manual
"usage_time":"2018-11-22 10:00:00"
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4701/4702/4703/4704
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4701"
NOTE: Not supported in North America CloudCore, but is supported in a Local OMC+BOSS
environment
Detail:
POST http://ipaddr:port/baicellsapi/usage/querycdr
param
Field Data Type Required Description
session_id String Yes Business serial number
imsi String No If the imsi is not empty query the specified IMSI’s
usage. If imsi is empty query all IMSI’s usage.
begin_time String Yes Time interval of queries, Format:yyyy-MM-dd
hh:mm:ss
The maximum time interval is 7 days.
end_time String Yes Time interval of queries, Format:yyyy-MM-dd
hh:mm:ss
The maximum time interval is 7 days.
55
BOSS API Manual
Example request:
POST /baicellsapi/usage/querybyhour HTTP/1.1
Content-Type: application/json
"session_id":"2016123456",
"imsi":"600000000000001",
"begin_time":"2018-11-22 08:00:00",
"end_time":"2018-11-22 12:00:00"
Success 200
Field Data Type Description
session_id String Business serial number
result_code String Successfully create a subscriber return code:200
cdr_infos JSONArray Return data list
imsi String imsi
total_usage String Unit (Byte)
up_usage String Unit (Byte)
down_usage String Unit (Byte)
duration String Unit(second)
cdrdate String The time to generate this CDR. Format:yyyy-MM-dd hh:mm:ss
Example response:
HTTP/1.1 200 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "200",
"cdr_infos":[
"imsi":"600000000000001",
"total_usage":"204800",
"up_usage":"1000",
"down_usage":"203800",
"duration":"300",
"cdrdate":"2018-11-22 12:14:32"
56
BOSS API Manual
}
Error 422
Field Data Type Description
session_id String Business serial number
result_code String Error return code: 4701/4702/4703/4705
message String Message
Example response:
HTTP/1.1 422 OK
Content-Type: application/json
"session_id": "2016123456",
"result_code": "4701"
57
BOSS API Manual
3. Appendix:
5. Call 2.1.7 (bind apn ip interface) to bind APN and IP for this subscriber.
6. Deactivate this subscriber and activate this subscriber again for the APN and IP to take effect.
58
BOSS API Manual
59