settings Params

Param name Description
id required . Must be String

The requested id

GET /v2/apps/7
200
{
  "id": 7,
  "name": "test intrateam staff oauth application",
  "description": null,
  "image": null,
  "website": null,
  "public": true,
  "scopes": [],
  "created_at": "2017-11-22T13:43:11.377Z",
  "updated_at": "2017-11-22T13:43:11.434Z",
  "owner": {
    "id": 74,
    "login": "pamidala",
    "url": "https://api.intra.42.fr/v2/users/pamidala"
  },
  "rate_limit": 1800,
  "roles": [
    {
      "id": 16,
      "name": "Official App",
      "description": "Approved application without rate limits"
    },
    {
      "id": 7,
      "name": "Basic Staff",
      "description": "Member of the staff, can manage community services, closes, exams and access advanced student data"
    },
    {
      "id": 11,
      "name": "Advanced Staff",
      "description": "Member of the staff, with higher privileges"
    },
    {
      "id": 1,
      "name": "Intrateam",
      "description": "manage all"
    }
  ]
}
curl  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" "https://api.intra.42.fr/v2/apps/7"

{
  "id": 7,
  "name": "test intrateam staff oauth application",
  "description": null,
  "image": null,
  "website": null,
  "public": true,
  "scopes": [],
  "created_at": "2017-11-22T13:43:11.377Z",
  "updated_at": "2017-11-22T13:43:11.434Z",
  "owner": {
    "id": 74,
    "login": "pamidala",
    "url": "https://api.intra.42.fr/v2/users/pamidala"
  },
  "rate_limit": 1800,
  "roles": [
    {
      "id": 16,
      "name": "Official App",
      "description": "Approved application without rate limits"
    },
    {
      "id": 7,
      "name": "Basic Staff",
      "description": "Member of the staff, can manage community services, closes, exams and access advanced student data"
    },
    {
      "id": 11,
      "name": "Advanced Staff",
      "description": "Member of the staff, with higher privileges"
    },
    {
      "id": 1,
      "name": "Intrateam",
      "description": "manage all"
    }
  ]
}
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/apps/7")
response.status
# => 200
response.parsed
# => {"id"=>7, "name"=>"test intrateam staff oauth application", "description"=>nil, "image"=>nil, "website"=>nil, "public"=>true, "scopes"=>[], "created_at"=>"2017-11-22T13:43:11.377Z", "updated_at"=>"2017-11-22T13:43:11.434Z", "owner"=>{"id"=>74, "login"=>"pamidala", "url"=>"https://api.intra.42.fr/v2/users/pamidala"}, "rate_limit"=>1800, "roles"=>[{"id"=>16, "name"=>"Official App", "description"=>"Approved application without rate limits"}, {"id"=>7, "name"=>"Basic Staff", "description"=>"Member of the staff, can manage community services, closes, exams and access advanced student data"}, {"id"=>11, "name"=>"Advanced Staff", "description"=>"Member of the staff, with higher privileges"}, {"id"=>1, "name"=>"Intrateam", "description"=>"manage all"}]}