live_help Notes

assignment This action requires one of theses roles: Advanced tutor

settings Params

Param name Description
id required . Must be String

The requested id

dashes_user optional , nil allowed . Must be a Hash
dashes_user[dash_id] optional . Must be Fixnum

The dash id. Must be unique in the scope of a given user.

dashes_user[user_id] optional . Must be Fixnum

The user id.

dashes_user[repo_url] optional , nil allowed . Must be String

The repo url.

dashes_user[repo_uuid] optional , nil allowed . Must be String

The repo uuid.

dashes_user[final_mark] optional , nil allowed . Must be Fixnum

The final mark.

PUT /v2/dashes_users/1
{
  "dashes_user": {
    "dash_id": "1",
    "user_id": "1"
  }
}
204
curl  -X PUT -H "Authorization: Bearer YOUR_ACCESS_TOKEN" -H "Content-Type: application/json" -d '{"dashes_user":{"dash_id":"1","user_id":"1"}}' "https://api.intra.42.fr/v2/dashes_users/1"
require "oauth2"
UID = "Your application uid"
SECRET = "Your application secret"
client = OAuth2::Client.new(UID, SECRET, site: "https://api.intra.42.fr")
token = client.client_credentials.get_token

params = {dashes_user: {dash_id: "1", user_id: "1"}}
response = token.put("/v2/dashes_users/1", params: params)
response.status
# => 204
response.parsed
# =>