Bajie Charging
  1. Cabinet Event Push
Bajie Charging
  • Open API
    • 1.Get Device Info
      GET
    • 2.Create Rent Order
      POST
    • 3.Query Rent Order Status
      POST
    • 4.Mark order status as completed
      POST
    • 5.Get Order Detail
      GET
    • 6.Get Deivice List
      POST
  • Advance API
    • Cabinet
      • Device Operation
      • eject the battery for the specified device slot by repair
      • Rent and eject the battery for the specified device slot
      • Query All Device List
      • Query details based on Device Id
      • get device list by shop id
      • get all device list by page
      • Query battery list based on Device Id
      • Query slot list based on Device Id
      • binding device to shop
      • Update cabinet advertising information
    • Shop
      • get all shop list
      • get shop detail
      • create new shop
      • update shop
      • Delete shop
    • PriceStrategy
      • 1.Get Price Strategy Page
      • 2.Get Price Strategy Detail
      • 3.Create Or Update Price Strategy
      • 4.Delete Price Strategy
      • 5.Shop Bind Price Strategy
      • 6.Shop Unbind Price Strategy
    • Order
      • Order list
  • Cabinet Event Push
    • Cabinet Event Push Config
      POST
    • GET Cabinet Event Push Config
      GET
    • Cabinet Event Push
      POST
  1. Cabinet Event Push

Cabinet Event Push

Developing
Production
https://developer.chargenow.top/cdb-open-api/v1
Production
https://developer.chargenow.top/cdb-open-api/v1
POST
https://developer.chargenow.top/cdb-open-api/v1
The URL you configured to receive cabinet event messages

Request

Body Params application/json
agentAccount
string 
Agent account
required
event
string 
Cabinet event
required
CABINET_ONLINE: Cabinet online event CABINET_OFFLINE: Cabinet offline event CABINET_STATUS: Cabinet status report event BATTERY_IN: Battery in eventBATTERY_BORROW_OUT: Battery be borrowed out event BATTERY_ABNORMAL_WARNING: Battery abnormality warning event BATTERY_POPUP: Battery repair pop-up event ADMIN_RENTAL_ORDER:Backstage management issues rental orders
eventData
object 
Cabinet event data
required
cabinetId
string 
Cabinet ID
required
infoStatus
string 
Cabinet online status
optional
Online or Offline
totalCount
integer 
Total number of charging slots
optional
rentableCount
integer 
Number of borrowed batteries
optional
returnableCount
integer 
Number of empty charging slots
optional
icCard
string 
IC card number
optional
clientIp
string 
Cabinet IP
optional
clientPort
string 
Cabinet IP PORT
optional
geoHash
string 
Cabinet side positioning, GEO hash value
optional
signal
string 
Cabinet end signal strength
optional
GPRS signal quality, range: 0-31; At least 19 is required to connect to the network, and 31 is best
batteryList
array [object {8}] 
Battery information
optional
onlineTime
string 
Cabinet online time
optional
offlineTime
string 
Cabinet offline time
optional
outBatteryId
string 
Eject battery's ID
optional
outSlot
integer 
Eject battery's slot
optional
orderId
string 
Order ID
optional
faultType
integer 
Rental fail types
optional
0.Other or undefined errors,
1.Authorize Battery fail
2.Unable to find this battery ID
3.Eject battery fail
4.Eject battery fail
5.Eject battery fail
9.Issue of lease command timed out
faultCause
string 
Rental fail cause
optional
0.Other or undefined errors,
1.Authorize Battery fail
2.Unable to find this battery ID
3.Eject battery fail
4.Eject battery fail
5.Eject battery fail
9.Issue of lease command timed out
returnBatteryId
string 
return battery ID
optional
returnSlot
integer 
return battery slot
optional
abnormalBatteryId
string 
Abnormal battery ID
optional
outStatus
string 
Popup status
required
Popup status 1-failure, 0-success
popupFailureDescription
string 
Pop-up failure instructions
required
Pop-up failure instructions
timestamp
string 
Notification Time
required
Example
{
    "agentAccount": "admins",
    "event": "CABINET_STATUS",
    "eventData": {
        "batteryList": [
            {
                "batteryFaultCause": "",
                "batteryFaultType": 0,
                "batteryId": "FECF007552",
                "faultCause": "",
                "faultType": 0,
                "infoStatus": "Online",
                "slot": 1,
                "vol": 100
            }
        ],
        "cabinetId": "BJX01553",
        "clientIp": "223.104.84.103",
        "clientPort": "10797",
        "geoHash": "",
        "infoStatus": "Online",
        "rentableCount": 1,
        "returnableCount": 7,
        "signal": "31",
        "totalCount": 8
    },
    "timestamp": "2023-12-29T15:53:18"
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://developer.chargenow.top/cdb-open-api/v1The URL you configured to receive cabinet event messages' \
--header 'Content-Type: application/json' \
--data-raw '{
    "agentAccount": "admins",
    "event": "CABINET_STATUS",
    "eventData": {
        "batteryList": [
            {
                "batteryFaultCause": "",
                "batteryFaultType": 0,
                "batteryId": "FECF007552",
                "faultCause": "",
                "faultType": 0,
                "infoStatus": "Online",
                "slot": 1,
                "vol": 100
            }
        ],
        "cabinetId": "BJX01553",
        "clientIp": "223.104.84.103",
        "clientPort": "10797",
        "geoHash": "",
        "infoStatus": "Online",
        "rentableCount": 1,
        "returnableCount": 7,
        "signal": "31",
        "totalCount": 8
    },
    "timestamp": "2023-12-29T15:53:18"
}'

Responses

🟢200成功
application/json
Body
object {0}
Example
{}
Previous
GET Cabinet Event Push Config
Built with