File: sphere_data.py

package info (click to toggle)
python-crownstone-cloud 1.4.11-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 240 kB
  • sloc: python: 1,126; makefile: 4
file content (103 lines) | stat: -rw-r--r-- 2,514 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
sphere_data = [
    {
        "name": "my_awesome_sphere",
        "uid": 69,
        "uuid": "uuid",
        "meshAccessAddress": "mesh_access_address",
        "aiName": "smart_ai",
        "aiSex": "null",
        "exitDelay": 600,
        "gpsLocation": {
            "lat": 69,
            "lng": 69
        },
        "id": "my_awesome_sphere_id",
        "ownerId": "owner_id",
        "createdAt": "date_created",
        "updatedAt": "date_updated"
    },
    {
        "name": "my_awesome_sphere_2",
        "uid": 42,
        "uuid": "uuid",
        "meshAccessAddress": "mesh_access_address",
        "aiName": "super_smart_ai",
        "aiSex": "null",
        "exitDelay": 600,
        "gpsLocation": {
            "lat": 42,
            "lng": 42
        },
        "id": "my_awesome_sphere_id_2",
        "ownerId": "owner_id",
        "createdAt": "date_created",
        "updatedAt": "date_updated"
    }
]

key_data = [
  {
    "sphereId": "my_awesome_sphere_id_2",
    "sphereKeys": [
      {
        "id": "admin_id",
        "keyType": "ADMIN_KEY",
        "key": "admin_key",
        "ttl": 0,
        "createdAt": "date_created"
      },
      {
        "id": "member_id",
        "keyType": "MEMBER_KEY",
        "key": "member_key",
        "ttl": 0,
        "createdAt": "date_created"
      },
      {
        "id": "basic_id",
        "keyType": "BASIC_KEY",
        "key": "basic_key",
        "ttl": 0,
        "createdAt": "date_created"
      },
      {
        "id": "localization_id",
        "keyType": "LOCALIZATION_KEY",
        "key": "localization_key",
        "ttl": 0,
        "createdAt": "date_created"
      },
      {
        "id": "service_data_id",
        "keyType": "SERVICE_DATA_KEY",
        "key": "service_data_key",
        "ttl": 0,
        "createdAt": "date_created"
      },
      {
        "id": "mesh_application_id",
        "keyType": "MESH_APPLICATION_KEY",
        "key": "mesh_application_key",
        "ttl": 0,
        "createdAt": "date_created"
      },
      {
        "id": "mesh_network_id",
        "keyType": "MESH_NETWORK_KEY",
        "key": "mesh_network_key",
        "ttl": 0,
        "createdAt": "date_created"
      }
    ]
  }
]

expected_key_data = {
    'ADMIN_KEY': 'admin_key',
    'MEMBER_KEY': 'member_key',
    'BASIC_KEY': 'basic_key',
    'LOCALIZATION_KEY': 'localization_key',
    'SERVICE_DATA_KEY': 'service_data_key',
    'MESH_APPLICATION_KEY': 'mesh_application_key',
    'MESH_NETWORK_KEY': 'mesh_network_key'
}