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

incorrect querystring param building for WordSearchAsync #43

Open
Swimburger opened this issue Aug 13, 2024 · 0 comments
Open

incorrect querystring param building for WordSearchAsync #43

Swimburger opened this issue Aug 13, 2024 · 0 comments
Assignees
Labels
kind/bug Something isn't working triage/confirmed Issue is well-defined and understood.

Comments

@Swimburger
Copy link
Contributor

When running the following code:

var client = new AssemblyAIClient(new ClientOptions
{
    ApiKey = "<YOUR_API_KEY>"
});

const string audioUrl = "https://github.com/AssemblyAI-Community/audio-examples/raw/main/20230607_me_canadian_wildfires.mp3";

var transcript = await client.Transcripts.TranscribeAsync(new TranscriptParams
{
    AudioUrl = audioUrl,
});

var matchesResponse = await client.Transcripts.WordSearchAsync(
    transcript.Id, 
    ["foo", "bar", "foo bar", "42"]
);

The WordSearchAsync method sends an HTTP request with the following URL:
https://api.assemblyai.com/v2/transcript/fb65d5a9-caed-477d-96bf-ee90337c7c5a/word-search?words=foo&words=bar&words=foo%20bar&words=42

But it should be:
https://api.assemblyai.com/v2/transcript/fb65d5a9-caed-477d-96bf-ee90337c7c5a/word-search?words=foo,bar,foo%20bar,42

A comma separated string

@Swimburger Swimburger added the kind/bug Something isn't working label Aug 13, 2024
@marcusolsson marcusolsson added the triage/confirmed Issue is well-defined and understood. label Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working triage/confirmed Issue is well-defined and understood.
Projects
None yet
Development

No branches or pull requests

3 participants