#### [Abblix\.Oidc\.Server](https://www.abblix.com/en/docs/api/abblix-oidc-server 'index')
### [Abblix\.Oidc\.Server\.Endpoints\.DynamicClientManagement\.Interfaces](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Endpoints.DynamicClientManagement.Interfaces 'Abblix\.Oidc\.Server\.Endpoints\.DynamicClientManagement\.Interfaces')

## IClientCredentialFactory Interface

Encapsulates client credential generation to maintain single responsibility and reduce constructor complexity\.
Separates credential\-specific concerns \(ID generation, secret generation, hashing, expiration\) from
the broader client registration process\.

```csharp
public interface IClientCredentialFactory
```

Derived  
↳ [ClientCredentialFactory](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Endpoints.DynamicClientManagement.ClientCredentialFactory 'Abblix\.Oidc\.Server\.Endpoints\.DynamicClientManagement\.ClientCredentialFactory')
### Methods

## IClientCredentialFactory\.Create\(string, string\) Method {#Abblix.Oidc.Server.Endpoints.DynamicClientManagement.Interfaces.IClientCredentialFactory.Create(string,string)}

Creates credentials with authentication\-method\-aware secret generation\.
Generates secrets only for methods requiring them \(client\_secret\_basic, client\_secret\_post, client\_secret\_jwt\),
avoiding unnecessary secret generation for public clients or private\_key\_jwt authentication\.

```csharp
Abblix.Oidc.Server.Endpoints.DynamicClientManagement.Interfaces.ClientCredentials Create(string tokenEndpointAuthMethod, string? clientId=null);
```
#### Parameters

###### `tokenEndpointAuthMethod` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String') {#Abblix.Oidc.Server.Endpoints.DynamicClientManagement.Interfaces.IClientCredentialFactory.Create(string,string).tokenEndpointAuthMethod}

Determines secret generation strategy based on OAuth 2\.0 authentication method\.

###### `clientId` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String') {#Abblix.Oidc.Server.Endpoints.DynamicClientManagement.Interfaces.IClientCredentialFactory.Create(string,string).clientId}

Allows pre\-registration scenarios where the client ID is externally provided\.

#### Returns
[ClientCredentials](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Endpoints.DynamicClientManagement.Interfaces.ClientCredentials 'Abblix\.Oidc\.Server\.Endpoints\.DynamicClientManagement\.Interfaces\.ClientCredentials')  
Complete credential set including both transmission format \(plain secret\) and storage format \(hash\)\.
