Persona Identifiers

Represents a unique identifier for a person. Statements that use these identifiers are linked to the persona that the identifier belongs to.

It is accessible through the following HTTP interfaces:

SCHEMA

Name

Description

Name

Description

_id

The id of this identifier.

organisation

The id of the organisation this identifier belongs to.

persona

The id of the persona this identifier belongs to.

ifi

A representation of the inverse functional identifier.

EXAMPLE

1 2 3 4 5 6 7 8 9 10 11 12 { "_id" : "59c1219936229d4ce9634601", "organisation" : "59c1219936229d4ce9634602", "persona": "59c1219936229d4ce9634603", "ifi": { "key": "account", "value": { "homePage": "http://www.example.org", "name": "example-user" } } }

INVERSE FUNCTIONAL IDENTIFIER

According to the xAPI specification, an Inverse Functional Identifier (IFI) is “a value of an Agent or Identified Group that is guaranteed to only ever refer to that Agent or Identified Group”.

SCHEMA

Name

Description

Name

Description

key

The type of IFI (accountmboxmbox_sha1sum, or openid).

value

The value of the IFI.

ACCOUNT IFI

1 2 3 4 5 6 7 { "key": "account", "value": { "homePage": "http://www.example.org", "name": "example-user" } }

MBOX IFI

1 2 3 4 { "key": "mbox", "value": "mailto:user@example.org" }

MBOX SHA1SUM IFI

1 2 3 4 { "key": "mbox_sha1sum", "value": "cc1e39b02974c5d21e792d7febcaa6018bb6c574" }

OPENID IFI

1 2 3 4 { "key": "openid", "value": "http://www.example.org/example-user" }

UPSERT HTTP INTERFACE

This interface creates or updates a persona identifier depending on whether the IFI already exists.

  • If the persona property is not set, a persona will be created if the identifier’s IFI doesn’t exist.

  • If the persona property is set, the persona must already exist. Otherwise, a 404 response code will be returned.

A request to the upsert route would look something like this:

1 2 3 4 5 6 7 8 9 10 11 12 13 POST http://www.example.org/api/v2/personaidentifier/upsert Authorization: YOUR_BASIC_AUTH Content-Type: application/json; charset=utf-8 { "ifi": { "key": "account", "value": { "homePage": "http://www.example.org", "name": "example-user" } } }

The interface will respond with a 200 response code, with detail the created/updated identifier.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 HTTP/1.1 200 OK Content-Type: application/json; charset=utf-8 { "_id" : "59c1219936229d4ce9634601", "organisation" : "59c1219936229d4ce9634602", "persona": "59c1219936229d4ce9634603", "ifi": { "key": "account", "value": { "homePage": "http://www.example.org", "name": "example-user" } } }

 

Learning Locker and the Squirrel logo are trademark of Learning Pool 2020 | Learning Locker is licensed under GPL 3.0.