Create an authentication profile

This topic describes how to programmatically get a list of authentication profiles and to create a new authentication profile.

Before continuing, ensure you are familiar with:

The remainder of this topic assumes that you have already authenticated the user and have obtained the authentication token necessary to invoke subsequent endpoints.

Get a list of authentication profiles

You can get a list of existing authentication profiles by invoking /AuthProfile/GetDecoratedProfileList.

POST https://mytenant.idaptive.app/AuthProfile/GetDecoratedProfileList

The Results collection in the response contains information about the profiles:

{  
	"success":true,
	"Result":{  
		"IsAggregate":false,
		"Count":21,
		"Columns":[  
			{  
				"Name":"Uuid",
				"IsHidden":false,
				"DDName":null,
				"Title":"Uuid",
				"DDTitle":null,
				"Description":null,
				"Type":12,
				"Format":null,
				"Width":36,
				"TableKey":null,
				"ForeignKey":null,
				"TableName":null
			},
			...
		],
		"FullCount":21,
		"Results":[  
			{  
				"Entities":[  
					{  
						"Type":"AuthProfileLink",
						"Key":"122f4...",
						"IsForeignKey":false
					}
				],
				"Row":{  
					"Uuid":"122f...",
					"Name":"Default New Device Login Profile",
					"ID":"122f...",
					"DurationInMinutes":720,
					"AdditionalData":{  
  
					},
					"Challenges":[  
						"UP"
					]
				}
			},
			...
		],
		"ReturnID":""
	},
	"Message":null,
	"MessageID":null,
	"Exception":null,
	"ErrorID":null,
	"ErrorCode":null,
	"InnerExceptions":null
}

Save a profile

To create an authentication profile, invoke /AuthProfile/authprofilesaveprofile.

When creating a new profile, there is no need to specify uuid.

POST https://mytenant.idaptive.app//AuthProfile/SaveProfile
  
{
	"settings":{
		"Name":"Main Auth Profile",
		"Challenges":[
			"UP",
			"OTP",
			"PF",
			"SMS",
			"EMAIL",
			"OATH",
			"RADIUS",
			"U2F",
			"SQ"
		],
		"Uuid":"14064051-018c-4877-a2a0-b4b17885a5f7",
		"DurationInMinutes":30,
		"AdditionalData":{
			"NumberOfQuestions":1
		}
	}
}

The Uuid field in the response contains the ID of the newly saved authentication profile.

{  
	"success":true,
	"Result":{  
		"Uuid":"ee4d5...",
		"Name":"Main Auth Profile",
		"DurationInMinutes":30,
		"Challenges":[  
			"UP",
			"OTP"
		],
		"AdditionalData":{  
  
		}
	},
	"Message":null,
	"MessageID":null,
	"Exception":null,
	"ErrorID":null,
	"ErrorCode":null,
	"InnerExceptions":null
}