Language

Represents the language of a scoresheet score.

URI
/api/v10/scoresheets/ID/score/ID/language

GET Get the language

Retrieve the score language code.

This API request returns the language code as a JSON encoded string or null, no language is stored.

Syntax
GET /api/v10/scoresheets/123/score/321/language
Host: apply.example.edu
Authorization: DREAM apikey="..."

Example request

Request
curl
curl \
  -X GET \
  -H "Authorization: DREAM apikey=\"YOUR-API-KEY\"" \
  "https://apply.example.edu/api/v10/scoresheets/123/scores/321/language"

Response headers

HeaderValueDescription
Content-Typeapplication/jsonThe media type of the resource
Content-Length1234The size of the response body in bytes

Response codes

Response codeDescription
200 OKThe language was successfully returned
404 Not FoundThe scoresheet does not have this score

Example response

Response
"en"

PUT Set the language

Set the language of a scoresheet score to the provided value.

Syntax
PUT /api/v10/scoresheets/123/scores/321/language
Host: apply.example.edu
Authorization: DREAM apikey="..."

Raw request body

The request body must contain a valid JSON string — an ISO 639-1 Alpha2 language identifier such as "en" or "it" enclosed in double quotes.

You cannot set a language to an empty value. Use the DELETE method for that.

Request body
"en"

Example request

Request
curl
curl \
  -X PUT \
  -H "Authorization: DREAM apikey=\"YOUR-API-KEY\"" \
  -d '"en"' \
  "https://apply.example.edu/api/v10/scoresheets/123/scores/321/language"

Response headers

HeaderValueDescription
Content-Typetext/plainThe media type of the resource
Content-Length0The size of the response body in bytes

Response codes

Response codeDescription
204 No ContentThe language was successfully saved
404 Not FoundThe scoresheet does not have this score
400 Bad RequestThe language code was not valid

DELETE Delete the language

Delete the language of a scoresheet score.

Syntax
DELETE /api/v10/scoresheets/123/scores/321/language
Host: apply.example.edu
Authorization: DREAM apikey="..."

Example request

Request
curl
curl \
  -X DELETE \
  -H "Authorization: DREAM apikey=\"YOUR-API-KEY\"" \
  "https://apply.example.edu/api/v10/scoresheets/123/scores/321/language"

Response headers

HeaderValueDescription
Content-Typetext/plainThe media type of the resource
Content-Length0The size of the response body in bytes

Response codes

Response codeDescription
204 No ContentThe language was successfully cleared
404 Not FoundThe scoresheet does not have this score