vscode-restclient
vscode-restclient copied to clipboard
graphQL: Using a variable with type Long!
{{dossierId}} has a type of Long in the variable object below.,
{{dossierId}} in the rest rest extension is displayed in red. If I add quotes like "{{dossierID}}", the red disapears, but then the query fails because the backend expects a Long and not a String.
what's the trick for this ? thanks in advance,
============================================================= @dossierId = {{dossier_createFromTemplate.response.body.data.dossier_createFromTemplate.$.id}}
@name dossier_addParticipant
POST {{gql_url}} Content-Type: application/json Accept: application/json Authorization: Bearer {{token}} X-REQUEST-TYPE: GraphQL
mutation dossier_addParticipantFromTemplate($personId: Long!, $dossierId: Long!) { dossier_addParticipantFromTemplate( dossierId: $dossierId personId: $personId ) { id } }
{ "dossierId": {{dossierId}}, "personId": 136472 }