Get a resource (v1) - lithnet/resourcemanagement-webservice GitHub Wiki

Used to get a resource from the FIM Service using its object ID or an anchor attribute/value pair

New implementations should use the v2 API call

Request

Method URL
GET /v1/resources/{id}
GET /v1/resources/{id}?locale={locale}
GET /v1/resources/{objectType}/{anchorAttributeName}/{anchorAttributeValue}
GET /v1/resources/{objectType}/{anchorAttributeName}/{anchorAttributeValue}?locale={locale}

URL Parameters

Parameter name Description
{id} The object ID of the resource
{locale} Specifies the language code of the culture to localize the representation of the resource in. This requires the appropriate language packs to be installed on the FIM/MIM Service. e.g en-US, de-de, ja-jp, es-es, it-it.
{objectType} The type of object to query
{anchorAttributeName} The name of the attribute that can be used to find this resource by its unique anchor value
{anchorAttributeValue} The value of the anchor attribute that uniquely identifies this resource

Request Body

This request type does not require a request body

Response

Response Codes

See the topic on error handling for the response codes that this API call can return.

Response Body

This method will return a JSON-formatted response containing the attributes and value pairs of this resource. Note that all attribute values are returned as JSON strings

Examples

Get a resource by its ID

Request

GET /v1/resources/f03f50c0-f40a-4370-8531-e5d025d22cb2/

Response

HTTP/1.1 200 OK
{
    "ObjectType": "Person",
    "ObjectID": "64f62191-b255-443b-bbe4-491a66300725",
    "ObjectSID": "AQUAAAAAAAUVAAAAFYLkaG78nJrWb05iFacCAA==",
    "CreatedTime": "2015-06-02T09:13:57.037",
    "Creator": "fb89aefa-5ea1-47f1-8890-abe7797d6497",
    "DomainConfiguration": "1aff46f4-5511-452d-bcbd-7f7b34b0fe14",
    "Manager": "64f62191-b255-443b-bbe4-491a66300725",
    "AccountName": "testuser",
    "AccountDisabled": "True",
    "UnixUid": "554422",
    "DisplayName": "Test User",
    "Domain": "FIM-DEV1",
    "Email": "[email protected]",
    "FirstName": "Test",
    "JobTitle": "Test User",
    "LastName": "User",
    "MVObjectID": "{7612EEDA-551E-E511-8CDB-005056B50BB9}",
    "jobTitles": [
        "Test1",
        "Test2"
    ],
}

Get the localized representation of a resource

Request

GET /v1/resources/50193587-8093-4e93-9162-dcdc11a80641/?locale=it-IT

Response

HTTP/1.1 200 OK
{
	"ObjectType": "ObjectTypeDescription",
	"ObjectID": "50193587-8093-4e93-9162-dcdc11a80641",
	"CreatedTime": "2015-05-26T19:22:43.483",
	"Description": "Definizione dichiarativa di un flusso di lavoro disponibile per l'esecuzione durante l'elaborazione delle richieste.",
	"DisplayName": "Definizione flusso di lavoro",
	"Name": "WorkflowDefinition",
	"UsageKeyword": "Microsoft.ResourceManagement.WebServices"
}