Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webhooks - "nicer" machine payloads #574

Open
psyciknz opened this issue Aug 6, 2024 · 0 comments
Open

Webhooks - "nicer" machine payloads #574

psyciknz opened this issue Aug 6, 2024 · 0 comments

Comments

@psyciknz
Copy link

psyciknz commented Aug 6, 2024

Any chance of simpler machine readable payloads.

Eg Adding a gas record is:

{
   "vehicleid": 1,
   "user": "psyciknz",
   "action": "Created Gas Record - Mileage: 129968"
}

where itd be real helpful if it could be, or include the following (and thinkinf of backwards compatibility here)

{
   "vehicleid": 1,
   "user": "psyciknz",
   "action": "Created Gas Record - Mileage: 129968",
   "type": "Created Gas Record"
   "value": {
          "Mileage": 129968
   }
}

and say for your example in the web hook docs

{
   "vehicleid": 1,
   "user": "psyciknz",
   "action": "Edited Service Record - Description: Oil Change",
   "type": "Edited Service Record"
   "value": {
          "Description": "Oil Change"
   }
}

thoughts? I'm seeing if I can work on a two way fuel record in lubelogger, updates traccar for the same device with the recorded odometer.

Potentially from traccar > device offline > update odometer record in lubelogger.
I'm actually using Home assistant as the engine to consume the lubelogger web hook.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant