Languages API

Languages are a set of languages which the learning objects can belong to, like portuguese, english and etc.

Updating languages

PUT /v1/languages/:id

Parameters

Name Description
id The id of the institution
language[name] The name of the language
language[code] The code of the language

Request

Headers

Accept: application/json
Content-Type: application/json
Access-Token: yLuOQjqoMNKh7OMTNWjqaQ
Client: udSzc0GQvuaOT9iQOHNY6w
Uid: drew.gutmann@fahey.io
Host: example.org
Cookie: 

Route

PUT /v1/languages/1

Body

{"language":{"name":"cum","code":"GY"}}

cURL

curl "https://api.portalmec.c3sl.ufpr.br/v1/languages/1" -d '{"language":{"name":"cum","code":"GY"}}' -X PUT \
	-H "Accept: application/json" \
	-H "Content-Type: application/json" \
	-H "Access-Token: yLuOQjqoMNKh7OMTNWjqaQ" \
	-H "Client: udSzc0GQvuaOT9iQOHNY6w" \
	-H "Uid: drew.gutmann@fahey.io"

Response

Headers

X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
Content-Type: application/json; charset=utf-8
Set-Cookie: _session_id=dGN5dE8yMldsYjB5cUx2YXpnRTdLdXdmbGp3UmVJZlIxSWE5YTUvNmpTMkZoVFZVdUNYRmxpNytHcEtiZzQxRWtLZXFwZE5UbTgrdi9YMGtLbjVLRllkUFVCcEE5OTN1UG01blhkY2VBdGRwb0F2QjFEZmphOVhQekoxSWVxSjlwbGxZWFlhQVluODd2TEs3UE9IaFYzYWZZUDVYRFZadjhpY3JrNDdhcCs3d2krdlVZVXpUdTlnSkI1TEd6OGkyLS1lK0JNVDZKdGFUc2ExdDlkMW42S1ZBPT0%3D--3f985a143dc9a471054447d5bda7349081668b12; path=/; HttpOnly
Vary: Origin
ETag: W/"77ab58aef2c9129ea83592de72baf67d"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: 42712399-2f92-4d8e-b395-07dd99adf05e
X-Runtime: 0.100121
Content-Length: 33

Status

200 OK

Body

{
  "id": 1,
  "name": "cum",
  "code": "GY"
}