Add a free agu in the past for a user which implies to delay the blackhole, Please follow the rules about the free agu. (if you dont know the rules contact a 42network staff)

live_help Notes

assignment This action requires one of theses roles: Advanced staff

settings Params

Param name Description
id required . Must be String

The user login

duration required . Must be String

Blackhole delay duration in day

reason optional . Must be String

Optional reason for the freeze.

POST /v2/users/:id/free_past_agu
{
  "duration": 2,
  "reason": "optional"
}
200
curl  -X POST -H "Authorization: Bearer YOUR_ACCESS_TOKEN" -H "Content-Type: application/json" -d '{"duration":2,"reason":"optional"}' "https://api.intra.42.fr/v2/users/:id/free_past_agu"
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 = {duration: 2, reason: "optional"}
response = token.post("/v2/users/:id/free_past_agu", params: params)
response.status
# => 200
response.parsed
# =>