settings Params

Param name Description
id required . Must be String

The requested id

comments powered by <span class='logo-disqus'>Disqus</span>
GET /v2/projects/5
200
{
  "id": 5,
  "name": "Quarter Finals",
  "slug": "hogwarts-quidditch-cup-quarter-finals",
  "description": null,
  "parent": {
    "name": "Hogwarts Quidditch Cup",
    "id": 4,
    "slug": "hogwarts-quidditch-cup",
    "url": "https://projects.intra.42.fr/hogwarts-quidditch-cup/mine"
  },
  "children": [],
  "objectives": null,
  "tier": null,
  "attachments": [],
  "created_at": "2017-03-06T14:59:05.006Z",
  "updated_at": "2017-03-06T14:59:05.080Z",
  "exam": false,
  "cursus": [
    {
      "id": 1,
      "created_at": "2017-03-06T14:58:43.965Z",
      "name": "Piscine C",
      "slug": "piscine-c"
    }
  ],
  "campus": [
    {
      "id": 1,
      "name": "Cluj",
      "time_zone": "Bucharest",
      "language": {
        "id": 3,
        "name": "Romanian",
        "identifier": "ro",
        "created_at": "2017-03-06T14:58:43.176Z",
        "updated_at": "2017-03-06T14:58:43.176Z"
      },
      "users_count": 16,
      "vogsphere_id": 1
    }
  ],
  "skills": [
    {
      "id": 4,
      "name": "Shell",
      "created_at": "2017-03-06T14:58:43.788Z"
    },
    {
      "id": 6,
      "name": "Basics",
      "created_at": "2017-03-06T14:58:43.800Z"
    }
  ],
  "videos": [],
  "tags": [
    {
      "id": 15,
      "name": "Hogwarts Quidditch Cup",
      "kind": "general"
    }
  ],
  "project_sessions": [
    {
      "id": 5,
      "solo": false,
      "begin_at": null,
      "end_at": null,
      "estimate_time": null,
      "duration_days": null,
      "terminating_after": null,
      "project_id": 5,
      "campus_id": null,
      "cursus_id": null,
      "created_at": "2017-03-06T14:59:05.021Z",
      "updated_at": "2017-03-06T14:59:05.021Z",
      "max_people": null,
      "is_subscriptable": true,
      "scales": [],
      "uploads": [],
      "team_behaviour": "user"
    }
  ]
}
curl  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" "https://api.intra.42.fr/v2/projects/5"

{
  "id": 5,
  "name": "Quarter Finals",
  "slug": "hogwarts-quidditch-cup-quarter-finals",
  "description": null,
  "parent": {
    "name": "Hogwarts Quidditch Cup",
    "id": 4,
    "slug": "hogwarts-quidditch-cup",
    "url": "https://projects.intra.42.fr/hogwarts-quidditch-cup/mine"
  },
  "children": [],
  "objectives": null,
  "tier": null,
  "attachments": [],
  "created_at": "2017-03-06T14:59:05.006Z",
  "updated_at": "2017-03-06T14:59:05.080Z",
  "exam": false,
  "cursus": [
    {
      "id": 1,
      "created_at": "2017-03-06T14:58:43.965Z",
      "name": "Piscine C",
      "slug": "piscine-c"
    }
  ],
  "campus": [
    {
      "id": 1,
      "name": "Cluj",
      "time_zone": "Bucharest",
      "language": {
        "id": 3,
        "name": "Romanian",
        "identifier": "ro",
        "created_at": "2017-03-06T14:58:43.176Z",
        "updated_at": "2017-03-06T14:58:43.176Z"
      },
      "users_count": 16,
      "vogsphere_id": 1
    }
  ],
  "skills": [
    {
      "id": 4,
      "name": "Shell",
      "created_at": "2017-03-06T14:58:43.788Z"
    },
    {
      "id": 6,
      "name": "Basics",
      "created_at": "2017-03-06T14:58:43.800Z"
    }
  ],
  "videos": [],
  "tags": [
    {
      "id": 15,
      "name": "Hogwarts Quidditch Cup",
      "kind": "general"
    }
  ],
  "project_sessions": [
    {
      "id": 5,
      "solo": false,
      "begin_at": null,
      "end_at": null,
      "estimate_time": null,
      "duration_days": null,
      "terminating_after": null,
      "project_id": 5,
      "campus_id": null,
      "cursus_id": null,
      "created_at": "2017-03-06T14:59:05.021Z",
      "updated_at": "2017-03-06T14:59:05.021Z",
      "max_people": null,
      "is_subscriptable": true,
      "scales": [],
      "uploads": [],
      "team_behaviour": "user"
    }
  ]
}
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/projects/5")
response.status
# => 200
response.parsed
# => {"id"=>5, "name"=>"Quarter Finals", "slug"=>"hogwarts-quidditch-cup-quarter-finals", "description"=>nil, "parent"=>{"name"=>"Hogwarts Quidditch Cup", "id"=>4, "slug"=>"hogwarts-quidditch-cup", "url"=>"https://projects.intra.42.fr/hogwarts-quidditch-cup/mine"}, "children"=>[], "objectives"=>nil, "tier"=>nil, "attachments"=>[], "created_at"=>"2017-03-06T14:59:05.006Z", "updated_at"=>"2017-03-06T14:59:05.080Z", "exam"=>false, "cursus"=>[{"id"=>1, "created_at"=>"2017-03-06T14:58:43.965Z", "name"=>"Piscine C", "slug"=>"piscine-c"}], "campus"=>[{"id"=>1, "name"=>"Cluj", "time_zone"=>"Bucharest", "language"=>{"id"=>3, "name"=>"Romanian", "identifier"=>"ro", "created_at"=>"2017-03-06T14:58:43.176Z", "updated_at"=>"2017-03-06T14:58:43.176Z"}, "users_count"=>16, "vogsphere_id"=>1}], "skills"=>[{"id"=>4, "name"=>"Shell", "created_at"=>"2017-03-06T14:58:43.788Z"}, {"id"=>6, "name"=>"Basics", "created_at"=>"2017-03-06T14:58:43.800Z"}], "videos"=>[], "tags"=>[{"id"=>15, "name"=>"Hogwarts Quidditch Cup", "kind"=>"general"}], "project_sessions"=>[{"id"=>5, "solo"=>false, "begin_at"=>nil, "end_at"=>nil, "estimate_time"=>nil, "duration_days"=>nil, "terminating_after"=>nil, "project_id"=>5, "campus_id"=>nil, "cursus_id"=>nil, "created_at"=>"2017-03-06T14:59:05.021Z", "updated_at"=>"2017-03-06T14:59:05.021Z", "max_people"=>nil, "is_subscriptable"=>true, "scales"=>[], "uploads"=>[], "team_behaviour"=>"user"}]}