ish
ish•9mo ago

GO support for Langfuse

Hi, I'm interested in using the Langfuse API to create traces and spans from my Golang backend but I noticed while reading the API reference (https://langfuse.com/docs/api-reference#tag/Trace) that there was not an endpoint for creating traces using the API. Could you please provide guidance or assistance on how I can effectively integrate tracing functionalities into my application using the Langfuse API? Any support or recommendations would be greatly appreciated. Thank you!
API reference - Langfuse
Langfuse HTTP API gives you full flexibility to integrate Langfuse into your existing systems.
8 Replies
Max
Max•9mo ago
Hi @ish, yes we removed the /traces API from the docs, as we migrated to a new batch endpoint. It can take multiple events at a time: https://langfuse.com/docs/api-reference#tag/Ingestion/operation/ingestion_batch
API reference - Langfuse
Langfuse HTTP API gives you full flexibility to integrate Langfuse into your existing systems.
Max
Max•9mo ago
You can also look at https://github.com/fern-api/fern-go and see how you can maybe generate a simple SDK for your use case. We have all the fern configuration for this endpoint here: https://github.com/langfuse/langfuse/blob/32a2a7956d9c97f09939f87b70cad9ae182463db/fern
GitHub
GitHub - fern-api/fern-go: Generate Go models and clients from your...
Generate Go models and clients from your API definition. - GitHub - fern-api/fern-go: Generate Go models and clients from your API definition.
GitHub
langfuse/fern at 32a2a7956d9c97f09939f87b70cad9ae182463db · langfus...
Open source LLM engineering platform. Debug, analyze and iterate together. - langfuse/langfuse
Max
Max•9mo ago
This might be the fastest way to get some boilerplate code up and running.
ish
ish•9mo ago
That's Awesome! Thank you.
Max
Max•9mo ago
Sure, i hope you managed to get something of the ground?
kanundrum
kanundrum•9mo ago
I'm working on this currently with @ish . I have something going but there spans aren't showing up in the dashboard. I don't get errors when calling the ingestion endpoint but the spans simply don't show up
kanundrum
kanundrum•9mo ago
still very much a work in progress but this is what we have so far - https://github.com/wepala/langfuse-go
GitHub
GitHub - wepala/langfuse-go
Contribute to wepala/langfuse-go development by creating an account on GitHub.
Max
Max•8mo ago
Guys, I just checked the repo and I love it! I hope you are making good progress and the spam issue from above is resolved? Happy to jump on a call to help you figure things out 🙂