heroiclabs / nakama-js

JavaScript client for Nakama server written in TypeScript.
https://heroiclabs.com/docs/nakama/client-libraries/javascript/
Apache License 2.0
198 stars 55 forks source link

Match listings in javascript SDK #89

Closed mshanak closed 2 years ago

mshanak commented 3 years ago

I am trying to use the Match listings function in my javascript client, but it always returns an empty result without any errors or exceptions. Following the code that I used:

let matches=this.client.listMatches(this.session);

Is there anything I am missing?

lugehorsam commented 3 years ago

Hey @mshanak, please see the type definition in the Javascript client for API usage:

listMatches(session: Session, limit?: number, authoritative?: boolean, label?: string, minSize?: number, maxSize?: number, query?: string): Promise<ApiMatchList>;

lugehorsam commented 3 years ago

I am going to transfer this issue to the nakama-js repository as it may be an issue with that client. In the meantime could you pass explicit parameters for those optionals I gave above?

lugehorsam commented 3 years ago

@mshanak if you view the matches inside the Nakama 3.0 console, do you see any running matches? Are they authoritative?