I'm currently creating a function that adds a player to the queue, using .CreateServerMatchmakingTicket(), but for some reason it is saying
{ code: 400, status: 'BadRequest', error: 'InvalidParams', errorCode: 1000, errorMessage: 'Invalid input parameters', errorDetails: { Members: [ 'The Members field is required.' ], QueueName: [ 'The QueueName field is required.' ], GiveUpAfterSeconds: [ 'The field GiveUpAfterSeconds must be between 5 and 3599.' ] } }
What I don't understand, is why it does this when I have all of the data, my only assumption is an issue with the entity token, which I've noticed when I'm calling GetEntityToken(), data.Entity.Id is just my title ID, which I'm not sure if is right, given that when you Login with a custom ID, it returns a completely different entity ID.
The developer secret key is in the code too, so it's not that.
This is what I'm doing to add a player to the queue, sorry if the code is awful, normally Lua!
function AddPlayerToQueue(Player) { PlayFabAuthentication.GetEntityToken({}, (Error, Token) => { console.log(Token.data) if (Error === null) { PlayFabMultiplayer.CreateServerMatchmakingTicket({ Entity: { Id: Token.data.Entity.Id, Type: Token.data.Entity.Type }, GiveUpAfterSeconds: 300, Members: { Player: { Entity: { Id: Token.data.Entity.Id, Type: Token.data.Entity.Type }, }, }, QueueName: "proqueue" }, (Err, Result) => { if (Err === null) { console.log(Result) } else { console.log(Err) } }) } }) },