POST https://graphql.seek.com/graphql HTTP/1.1
Accept-Language: en-AU
Authorization: Bearer PARTNER_TOKEN_HERE
Content-Type: application/json
User-Agent: example-application/1.2.3
X-Request-Id: a9e3d78d-576d-470b-b1d2-52f4921be25c
X-Session-Id: b5a8774c-c450-4906-a25c-861bce129106
{"query": "{ version }"
}#!/bin/sh
# In practice, propagate language preferences from the end-user client.# https://developer.seek.com/graphql/in-practice#content-localisationacceptLanguage='en-AU'
# In practice, retrieve and cache an access token dynamically at runtime.# https://developer.seek.com/authaccessToken=''
# In practice, use your application name and version from configuration.# https://developer.seek.com/graphql/in-practice#tracing-requestsuserAgent='example-application/1.2.3'
# In practice, share the session ID among requests in a given interaction.# https://developer.seek.com/graphql/in-practice#tracing-requestssessionId="$(uuidgen)"
# In practice, be wary of code injection.# https://developer.seek.com/graphql/in-practice#variablesdata='{"query": "{ version }"}'
# In practice, use a GraphQL client and something other than a Bash script.# https://developer.seek.com/graphql/in-practice#client-libraries-and-tools# https://graphql.org/community/tools-and-libraries/?tags=clientresponse="$(
curl \--data "${data}" \
--header "Accept-Language: ${acceptLanguage}" \
--header "Authorization: Bearer ${accessToken}" \
--header 'Content-Type: application/json' \--header "User-Agent: ${userAgent}" \
--header "X-Request-Id: $(uuidgen)" \
--header "X-Session-Id: ${sessionId}" \
--request POST \
--silent \
--write-out '\n%{http_code}' \
'https://graphql.seek.com/graphql'
)"
echo "${response}" | tail -n 1
# 200
echo "${response}" | head -n 1
# {"data":{"version":"abcdefa.12345"},"extensions":{"requestLatency":1}}
version query.
A valid access token is required in the Authorization request header for other operations,
as covered in the previous Auth section.We provide GraphQL code samples across the Developer Site to demonstrate the implementation of features that are described in the documentation:query ($id: String!) {
hiringOrganization(id: $id) {
name
}
}https://graphql.seek.com/graphql.
See GraphQL in practice for more information about our GraphQL endpoint and client tooling.