Show / Hide Table of Contents

Class AccessToken

An access token that can be used for authentication to make calls to Ethos Integration. To get an Authorization header that can be used to make HTTP requests, use the GetAuthHeader() method. This will return a Dictionary<string, string> containing a single entry of the Authorization header key/value pair. That can be used as-is or added to an existing headers map to pass to the EthosClient making the requests.

Inheritance
System.Object
AccessToken
Namespace: Ellucian.Ethos.Integration.Authentication
Assembly: Ellucian.Ethos.Integration.dll
Syntax
public class AccessToken : object

Constructors

AccessToken(String, DateTime)

Creates an instance of an access token that expires at the given time.

Declaration
public AccessToken(string token, DateTime expirationTime)
Parameters
Type Name Description
System.String token

An encoded JWT string.

DateTime expirationTime

The time when this token will expire.

Properties

ExpirationTime

Gets the time when this access token will expire.

Declaration
public DateTime ExpirationTime { get; }
Property Value
Type Description
DateTime

System.DateTime

Token

An encoded JWT string.

Declaration
protected string Token { get; }
Property Value
Type Description
System.String

System.string

Methods

GetAuthHeader()

Get an HTTP Authorization header containing the access token.

Declaration
public Dictionary<string, string> GetAuthHeader()
Returns
Type Description
Dictionary<System.String, System.String>

Authorization header containing the access token.

IsValid()

Determine if the session is still valid.

Declaration
public bool IsValid()
Returns
Type Description
System.Boolean

If the token is still valid.

In This Article
Back to top Generated by DocFX