Return the achievement specified by the :id parameter. Invisibles achievements need at least the basic_staff role.

settings Params

Param name Description
id required . Must be String

The requested id

comments powered by <span class='logo-disqus'>Disqus</span>
GET /v2/events/2
200
{
  "id": 2,
  "name": "Virginia dwarves",
  "description": "Facilis twee ut bespoke. Banh mi whatever schlitz ramps. Pickled at disrupt totam. Repellat neutra cupiditate photo booth.",
  "location": "Western Marquardt Academy",
  "kind": "rush",
  "max_people": 16,
  "nbr_subscribers": 0,
  "begin_at": "2017-03-07T14:59:35.063Z",
  "end_at": "2017-03-07T16:59:35.063Z",
  "campus_ids": [
    3
  ],
  "cursus_ids": [
    2
  ],
  "created_at": "2017-03-06T14:59:35.083Z",
  "updated_at": "2017-03-06T14:59:35.106Z"
}
curl  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" "https://api.intra.42.fr/v2/events/2"

{
  "id": 2,
  "name": "Virginia dwarves",
  "description": "Facilis twee ut bespoke. Banh mi whatever schlitz ramps. Pickled at disrupt totam. Repellat neutra cupiditate photo booth.",
  "location": "Western Marquardt Academy",
  "kind": "rush",
  "max_people": 16,
  "nbr_subscribers": 0,
  "begin_at": "2017-03-07T14:59:35.063Z",
  "end_at": "2017-03-07T16:59:35.063Z",
  "campus_ids": [
    3
  ],
  "cursus_ids": [
    2
  ],
  "created_at": "2017-03-06T14:59:35.083Z",
  "updated_at": "2017-03-06T14:59:35.106Z"
}
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

response = token.get("/v2/events/2")
response.status
# => 200
response.parsed
# => {"id"=>2, "name"=>"Virginia dwarves", "description"=>"Facilis twee ut bespoke. Banh mi whatever schlitz ramps. Pickled at disrupt totam. Repellat neutra cupiditate photo booth.", "location"=>"Western Marquardt Academy", "kind"=>"rush", "max_people"=>16, "nbr_subscribers"=>0, "begin_at"=>"2017-03-07T14:59:35.063Z", "end_at"=>"2017-03-07T16:59:35.063Z", "campus_ids"=>[3], "cursus_ids"=>[2], "created_at"=>"2017-03-06T14:59:35.083Z", "updated_at"=>"2017-03-06T14:59:35.106Z"}