Connect by mac address - aliconnect/aliconnect.sdk GitHub Wiki

Connect a device by MAC address

Voorbereiding

Table auth.mac

  • address string MAC address van device, b.v. A1-B2-C3-D4-E5-F6
  • client_id int ID van client
  • aud int ID van audience (systeem)
  • sub int ID van subject (device)
  • nonce uniqueidentifier = null UID wordt ingevuld gedurende het aanmeld proces.

File /webroot/config.json

  • client_id client_id of the system where the device will retreive it's data. client_id of the DWS
  • api of dws Data Warehouse Server connection settings
  • auth of as Authentication Server connection settings

wellicht verplaats de client_id onder de api server settings. Tevens wordt de api server setting wellicht dws settings. Dit is namelijk de Data Warehouse Server

{
    "api": {
        "client_id": "A1A1A1A1-A1A1-A1A1-A1A1-A1A1A1A1A1A1",
        "hostname": "aliconnect.nl",
        "port": 443,
        "basePath": "/api"
    },
    "auth": {
        "hostname": "login.aliconnect.nl",
        "port": 443,
        "basePath": "/oauth2"
    }
}

/secret.json

{
}

Na opstarten

/webroot/config.json

Is aangepast

{
    "client_id": "A1A1A1A1-A1A1-A1A1-A1A1-A1A1A1A1A1A1",
    "api": {
        "client_id": "A1A1A1A1-A1A1-A1A1-A1A1-A1A1A1A1A1A1",
        "hostname": "aliconnect.nl",
        "port": 443,
        "basePath": "/api"
    },
    "auth": {
        "hostname": "login.aliconnect.nl",
        "port": 443,
        "basePath": "/oauth2"
    }
}

/secret.json

{
    "client_secret": "A1A1A1A1-A1A1-A1A1-A1A1-A1A1A1A1A1A1",
    "refresh_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJzaGEyNTYifQ.eyJpc3MiOiJsb...MjI0fQ.DW-fCSTtX9QzaJ43DgGPrF5j18oaqqwPmvxpLTaFSAo"
}
⚠️ **GitHub.com Fallback** ⚠️