# IDocumentIdProvider Methods

[Type overview](/orleans/docs/api/csharp/microsoft.orleans.persistence.cosmos/orleans.persistence.cosmos.idocumentidprovider/)

## GetDocumentIdentifiers(string, GrainId) {#getdocumentidentifiers-string-orleans-runtime-grainid-f25fe1aa}

[Dedicated page](/orleans/docs/api/csharp/microsoft.orleans.persistence.cosmos/orleans.persistence.cosmos.idocumentidprovider/methods/getdocumentidentifiers-string-orleans-runtime-grainid-f25fe1aa/)

```csharp
public abstract ValueTask<(string DocumentId, string PartitionKey)> IDocumentIdProvider.GetDocumentIdentifiers(string grainType, GrainId grainId)
```

Gets the document identifier for the specified grain.

### Parameters

- `grainType` (`string`): The grain type.
- `grainId` (`GrainId`): The grain identifier.

### Returns

The document id and partition key.
