Domain Documentation
Domain Sensocto.Accounts
Class Diagram
classDiagram
class Token {
UUID id
String jti
String purpose
Map extra_data
store_confirmation_changes(String token, Map extra_data, String purpose)
get_confirmation_changes(String jti)
read_expired()
read()
expired()
get_token(String token, String jti, String purpose)
revoked?(String token, String jti)
revoke_token(String token, Map extra_data)
store_token(String token, Map extra_data, String purpose)
expunge_expired()
}
class User {
UUID id
CiString email
confirm(String confirm, CiString email)
read()
get_by_subject(String subject)
get_by_email(CiString email)
sign_in_with_magic_link(String token)
request_magic_link(CiString email)
change_password(String current_password, String password, String password_confirmation)
sign_in_with_password(CiString email, String password)
sign_in_with_token(String token)
register_with_password(CiString email, String password, String password_confirmation)
request_password_reset_token(CiString email)
reset_password_with_token(String reset_token, String password, String password_confirmation)
}
ER Diagram
erDiagram
Token {
UUID id
String jti
String purpose
Map extra_data
}
User {
UUID id
CiString email
}
Resources
Token
Attributes
| Name |
Type |
Description |
| created_at |
UtcDatetimeUsec |
|
| id |
UUID |
|
| jti |
String |
|
| subject |
String |
|
| expires_at |
UtcDatetime |
|
| purpose |
String |
|
| extra_data |
Map |
|
| inserted_at |
UtcDatetimeUsec |
|
| updated_at |
UtcDatetimeUsec |
|
Actions
| Name |
Type |
Input |
Description |
| store_confirmation_changes |
create |
- token String
- extra_data Map attribute
- purpose String attribute
|
|
| get_confirmation_changes |
read |
|
|
| read_expired |
read |
|
|
| read |
read |
|
|
| expired |
read |
|
Look up all expired tokens. |
| get_token |
read |
- token String
- jti String
- purpose String
|
Look up a token by JTI or token, and an optional purpose. |
| revoked? |
action |
|
Returns true if a revocation token is found for the provided token |
| revoke_token |
create |
- token String
- extra_data Map attribute
|
Revoke a token. Creates a revocation token corresponding to the provided token. |
| store_token |
create |
- token String
- extra_data Map attribute
- purpose String attribute
|
Stores a token used for the provided purpose. |
| expunge_expired |
destroy |
|
Deletes expired tokens. |
User
Attributes
| Name |
Type |
Description |
| confirmed_at |
UtcDatetimeUsec |
|
| id |
UUID |
|
| email |
CiString |
|
| hashed_password |
String |
|
Actions
| Name |
Type |
Input |
Description |
| confirm |
update |
- confirm String
- email CiString attribute
|
|
| read |
read |
|
|
| get_by_subject |
read |
|
Get a user by the subject claim in a JWT |
| get_by_email |
read |
|
Looks up a user by their email |
| sign_in_with_magic_link |
create |
- token String The token from the magic link that was sent to the user
|
Sign in or register a user with magic link. |
| request_magic_link |
action |
|
|
| change_password |
update |
- current_password String
- password String
- password_confirmation String
|
|
| sign_in_with_password |
read |
- email CiString The email to use for retrieving the user.
- password String The password to check for the matching user.
|
Attempt to sign in using a email and password. |
| sign_in_with_token |
read |
- token String The short-lived sign in token.
|
Attempt to sign in using a short-lived sign in token. |
| register_with_password |
create |
- email CiString
- password String The proposed password for the user, in plain text.
- password_confirmation String The proposed password for the user (again), in plain text.
|
Register a new user with a email and password. |
| request_password_reset_token |
action |
|
Send password reset instructions to a user if they exist. |
| reset_password_with_token |
update |
- reset_token String
- password String The proposed password for the user, in plain text.
- password_confirmation String The proposed password for the user (again), in plain text.
|
|
Domain Sensocto.Sensors
Class Diagram
classDiagram
class Sensor {
UUID id
String name
UUID sensor_type_id
String mac_address
Integer sampling_rate
Map configuration
}
class SensorAttribute {
UUID id
}
class SensorType {
}
class Connector {
UUID id
}
class ConnectorSensorType {
}
class RoomSensorType {
}
class Room {
UUID id
}
class SensorConnection {
}
Connector -- ConnectorSensorType
Connector -- Sensor
Connector -- SensorConnection
ConnectorSensorType -- SensorType
Room -- RoomSensorType
Room -- SensorConnection
RoomSensorType -- SensorType
Sensor -- SensorAttribute
Sensor -- SensorConnection
Sensor -- SensorType
ER Diagram
erDiagram
Sensor {
UUID id
String name
UUID sensor_type_id
String mac_address
Integer sampling_rate
Map configuration
}
SensorAttribute {
UUID id
}
SensorType {
}
Connector {
UUID id
}
ConnectorSensorType {
}
RoomSensorType {
}
Room {
UUID id
}
SensorConnection {
}
Connector ||--|| ConnectorSensorType : ""
Connector ||--|| Sensor : ""
Connector ||--|| SensorConnection : ""
ConnectorSensorType ||--|| SensorType : ""
Room ||--|| RoomSensorType : ""
Room ||--|| SensorConnection : ""
RoomSensorType ||--|| SensorType : ""
Sensor ||--|| SensorAttribute : ""
Sensor ||--|| SensorConnection : ""
Sensor ||--|| SensorType : ""
Resources
Sensor
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| name |
String |
|
| sensor_type_id |
UUID |
|
| mac_address |
String |
|
| sampling_rate |
Integer |
|
| configuration |
Map |
|
| connector_id |
UUID |
|
| sensor_type_rel_id |
UUID |
|
Actions
| Name |
Type |
Input |
Description |
SensorAttribute
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| sensor_id |
UUID |
|
| attribute_id |
Atom |
|
| values |
Map |
|
Actions
| Name |
Type |
Input |
Description |
SensorType
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| name |
Atom |
|
| allowed_attributes |
Atom[] |
|
Actions
| Name |
Type |
Input |
Description |
Connector
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| name |
String |
|
| connector_type |
Atom |
|
| configuration |
Map |
|
Actions
| Name |
Type |
Input |
Description |
ConnectorSensorType
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| connector_id |
UUID |
|
| sensor_type_id |
UUID |
|
Actions
| Name |
Type |
Input |
Description |
RoomSensorType
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| room_id |
UUID |
|
| sensor_type_id |
UUID |
|
Actions
| Name |
Type |
Input |
Description |
Room
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| name |
String |
|
| description |
String |
|
| configuration |
Map |
|
Actions
| Name |
Type |
Input |
Description |
SensorConnection
Attributes
| Name |
Type |
Description |
| id |
UUID |
|
| sensor_id |
UUID |
|
| connector_id |
UUID |
|
| room_id |
UUID |
|
| connected_at |
UtcDatetime |
|
| disconnected_at |
UtcDatetime |
|
Actions
| Name |
Type |
Input |
Description |