See api-docs Menu

Developer Overview

Welcome to the OneLogin API.

This API is based on RESTful principles, is secured by OAuth 2.0, and provides JSON messages, search, pagination, sorting,¬†and¬†filtering.

Base Url

The base url for the API varies by region. Use the region that your OneLogin account resides in.

  • US:
  • EU:


The version number for the api is indicated in the url. Versioning starts at 1 and increases as we make major changes to any oft he APIs or their payloads. It is recommended to always use the latest version.

For example, Get Users API is currently on version 1 `GET /api/1/users` where as Get Apps API is on version 2 `GET /api/2/apps`.

API Endpoints


App Resource

List Apps

Get App

Create App

Update App

Delete Parameter

Delete App


List Connectors


User Resource

Get Users

Get User by ID

Get Apps for a User

Get Roles Assigned to a User

Get Custom Attribute Fields

Create User

Delegate Authentication

Update User

Assign Roles to a User

Remove Roles for a User

Set Password Using Cleartext

Set Password Using SHA-256

Set Custom Attribute Values for a User

Set User State

Log User Out

Lock User Account

Delete User


Event Resource and Types

Get Events

Get Event Types

Get Event by ID

OAuth 2.0 Tokens

Generate Tokens

Refresh Tokens

Revoke Tokens

Get Rate Limit

Multi-Factor Authentication


Get Available Factors

Enroll a Factor

Get Enrolled Factors

Activate a Factor

Verify a Factor

Generate MFA Token

Custom Login Pages

Log in User via API

Create Session Login Token

Verify Factor

Session Via API Token

SAML Assertions

Generate SAML Assertion

Verify Factor


Get Roles

Get Role by ID


Get Groups

Get Group by ID


Generate Invite Link

Send Invite Link

Embed Apps

Embed Apps

Have a Question?

Have a how-to question? Seeing a weird error? Ask us about it on StackOverflow.

Found a bug? Submit a support ticket.

Have a product idea or request? Share it with us in our Ideas Portal.

StackOverflow discussions about "[onelogin] api"

  • 9

    Q: AWS API credentials with OneLogin SAML and MFA

    Asked Oct 30 2016

    fully re-authenticate to OneLogin (including MFA) every 60 minutes as the AWS temporary credentials expire. I think that won't fly - our users are accustomed to permanent API credentials tied to a … We want to allow our users to retrieve a set of temporary CLI credentials for a given AWS role by signing in to OneLogin with password and MFA. We have a working solution, but it requires the user to …

  • 8

    A: OneLogin REST API with PowerShell's Invoke-RestMethod

    Answered Sep 05 2016

    ://$id' ` -Headers @{ Authorization = "bearer:$token" } ` -Body ( @{ phone = "7709746046" } | ConvertTo-Json ) ` -Method Put … = '' ContentType = "application/json" Headers = @{authorization = "bearer:$token" } Body = @{role_id_array = @(143175 …

  • 5

    Q: How to use onelogin SSO with AngularJS?

    Asked Jun 20 2016

    questions: 1> Onelogin is using SAML instead of OpenID Connect. I am not asking what's the difference between these two, but what is recommended since everyone is moving towards OpenID Connect? 2> Does Onelogin supports AngularJS? I don't see any documentation for onelogin API with AngularJS & Node See Here … I was looking into Onelogin for SSO. We have applications written in .NET, AngularJS + Node. None of these applications are mobile applications. After going through their documentation I have few …

  • 3

    Q: SAML for Native Mobile Apps(Android and IOS)

    Asked Mar 27 2018

    I have been searching for quite long time, whether SAML Authentication available for Mobile Apps. I went through the oneLogin developer portal completely, but could not find any documents on Android and IOS Api. Can somebody please confirm me whether SAML gives support to Mobile Apps or not. …

  • 3

    Q: Onelogin and ID Token : grant request is invalid

    Asked Jun 28 2018

    I am using connect id to deal with rstudio login. After retreiving the code The API returns an error:{"error":"invalid_grant","error_description":"grant request is invalid"} and i have no idea why … and is passed as is. On Onelogin side everything seems configured as it should. My suspicion is on the PHP Curl code but I don't know what is missing/wrong …