kimai / kimai

Kimai is a web-based multi-user time-tracking application. Works great for everyone: freelancers, companies, organizations - everyone can track their times, generate reports, create invoices and do so much more. SaaS version available at https://www.kimai.cloud
https://www.kimai.org
GNU Affero General Public License v3.0
3.1k stars 543 forks source link

Tags JSON missing key for key value pair #4787

Closed treverehrfurth closed 4 months ago

treverehrfurth commented 4 months ago

Describe the issue

For work we need to export all our Kimai data into Snowflake. We are using Matillion DPC to automate the endpoints/ingestion and everything's been great except Tags. the API call for getting all the tags lists it without a key, and just shows the value.

Example:

[
    "Client Weekly Sync",
    "Daily Standup",
    "Engineer Synch"
]

Automated API tools struggle with handling a key value pair with no key from the JSON.

Is this something that can be added to make it play well with other data integration/development tools?

I already tried

Kimai version

2.13

How do you run Kimai?

Docker

Which PHP version are you using?

8.2

Logfile

No response

Screenshots

No response

kevinpapst commented 4 months ago

[] is an array, {} is a key-value map. In which world is this a bug? Did I miss something obvious? Sounds as if that Snowflake app has a flaw.

treverehrfurth commented 4 months ago

Okay sorry, I don't spend my life in JSON. And you're right its more of a feature request to add {"tags": ["xyz"]} instead of just an array vs a bug, my bad.

In which world is Matillion a Snowflake app? Its an enterprise SaaS data pipeline builder with HQ in multiple countries and it needs an identifier for the array otherwise it parses everything as null.

My company is a Matillion Partner and i've reached out to support to figure out a way to handle this, but that could be months to never as its not high on their priority list as every api call i've ever used prior was a key-value map. I figured I could also ask you as the developer here to add a wrapper around the tags API thinking that would be the easiest boulder to move. Sorry for asking.

kevinpapst commented 4 months ago

Your post has so many flaws that I am just going to close here instead of answering.