Skip to content
This repository was archived by the owner on Nov 15, 2024. It is now read-only.

Commit c929735

Browse files
authored
fix: Session creation request when sending body (#242)
The API was ignoring the data passed as URL parameters but takes it into account when passed in the body. https://axios-http.com/docs/req_config - Axios's `params` sets URL parameters - What the API seems to be expecting here is the body of the request to contain the data
1 parent 9ce3033 commit c929735

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

src/seam-connect/routes.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -515,22 +515,22 @@ export abstract class Routes {
515515
}
516516

517517
public readonly clientSessions = {
518-
create: (params: ClientSessionsCreateRequest) =>
518+
create: (data: ClientSessionsCreateRequest) =>
519519
this.makeRequestAndFormat<ClientSessionsCreateResponse>(
520520
"client_session",
521521
{
522522
url: "/client_sessions/create",
523523
method: "POST",
524-
params,
524+
data,
525525
}
526526
),
527-
getOrCreate: (params: ClientSessionsGetOrCreateRequest) =>
527+
getOrCreate: (data: ClientSessionsGetOrCreateRequest) =>
528528
this.makeRequestAndFormat<ClientSessionsGetOrCreateResponse>(
529529
"client_session",
530530
{
531531
url: "/client_sessions/create",
532532
method: "PUT",
533-
params,
533+
data,
534534
}
535535
),
536536
list: (params: ClientSessionsListRequest) =>

0 commit comments

Comments
 (0)