Credential Operations - Create Or Update
Creates or updates a credential.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/credentials/{credentialName}?api-version=2018-06-01
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
credential
|
path | True |
string minLength: 1maxLength: 127 pattern: ^([_A-Za-z0-9]|([_A-Za-z0-9][-_A-Za-z0-9]{0,125}[_A-Za-z0-9]))$ |
Credential name |
factory
|
path | True |
string minLength: 3maxLength: 63 pattern: ^[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*$ |
The factory name. |
resource
|
path | True |
string minLength: 1maxLength: 90 pattern: ^[-\w\._\(\)]+$ |
The resource group name. |
subscription
|
path | True |
string |
The subscription identifier. |
api-version
|
query | True |
string |
The API version. |
Request Header
Name | Required | Type | Description |
---|---|---|---|
If-Match |
string |
ETag of the credential entity. Should only be specified for update, for which it should match existing entity or can be * for unconditional update. |
Request Body
Name | Required | Type | Description |
---|---|---|---|
properties | True | Credential: |
Properties of credentials. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
OK. |
|
Other Status Codes |
An error response received from PUT credential operation. |
Security
azure_auth
Azure Active Directory OAuth2 Flow.
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
Name | Description |
---|---|
user_impersonation | impersonate your user account |
Examples
Credentials_Create
Sample request
PUT https://management.azure.com/subscriptions/12345678-1234-1234-1234-12345678abc/resourceGroups/exampleResourceGroup/providers/Microsoft.DataFactory/factories/exampleFactoryName/credentials/exampleCredential?api-version=2018-06-01
{
"properties": {
"type": "ManagedIdentity",
"typeProperties": {
"resourceId": "/subscriptions/12345678-1234-1234-1234-12345678abc/resourcegroups/exampleResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/exampleUami"
}
}
}
Sample response
Date: Sat, 16 Jun 2018 00:37:34 GMT
X-Content-Type-Options: nosniff
x-ms-ratelimit-remaining-subscription-writes: 1196
x-ms-request-id: b3b336b3-b203-4654-9cb6-a3a8d3a4b5de
x-ms-correlation-request-id: b3b336b3-b203-4654-9cb6-a3a8d3a4b5de
{
"id": "/subscriptions/12345678-1234-1234-1234-12345678abc/resourceGroups/exampleResourceGroup/providers/Microsoft.DataFactory/factories/exampleFactoryName/credentials/exampleCredential",
"name": "exampleCredential",
"type": "Microsoft.DataFactory/factories/credentials",
"properties": {
"type": "ManagedIdentity",
"typeProperties": {
"resourceId": "/subscriptions/12345678-1234-1234-1234-12345678abc/resourcegroups/exampleResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/exampleUami"
}
},
"etag": "0a0062d4-0000-0000-0000-5b245bcf0000"
}
Definitions
Name | Description |
---|---|
Azure |
Azure Key Vault secret reference. |
Cloud |
The object that defines the structure of an Azure Data Factory error response. |
Credential |
Credential resource type. |
Linked |
Linked service reference type. |
Managed |
Managed identity credential. |
Service |
Service principal credential. |
Type |
Linked service reference type. |
AzureKeyVaultSecretReference
Azure Key Vault secret reference.
Name | Type | Description |
---|---|---|
secretName |
object |
The name of the secret in Azure Key Vault. Type: string (or Expression with resultType string). |
secretVersion |
object |
The version of the secret in Azure Key Vault. The default value is the latest version of the secret. Type: string (or Expression with resultType string). |
store |
The Azure Key Vault linked service reference. |
|
type |
string:
Azure |
Type of the secret. |
CloudError
The object that defines the structure of an Azure Data Factory error response.
Name | Type | Description |
---|---|---|
error.code |
string |
Error code. |
error.details |
Array with additional error details. |
|
error.message |
string |
Error message. |
error.target |
string |
Property name/path in request associated with error. |
CredentialResource
Credential resource type.
Name | Type | Description |
---|---|---|
etag |
string |
Etag identifies change in the resource. |
id |
string |
The resource identifier. |
name |
string |
The resource name. |
properties | Credential: |
Properties of credentials. |
type |
string |
The resource type. |
LinkedServiceReference
Linked service reference type.
Name | Type | Description |
---|---|---|
parameters |
object |
Arguments for LinkedService. |
referenceName |
string |
Reference LinkedService name. |
type |
Linked service reference type. |
ManagedIdentityCredential
Managed identity credential.
Name | Type | Description |
---|---|---|
annotations |
object[] |
List of tags that can be used for describing the Credential. |
description |
string |
Credential description. |
type |
string:
Managed |
Type of credential. |
typeProperties.resourceId |
string |
The resource id of user assigned managed identity |
ServicePrincipalCredential
Service principal credential.
Name | Type | Description |
---|---|---|
annotations |
object[] |
List of tags that can be used for describing the Credential. |
description |
string |
Credential description. |
type |
string:
Service |
Type of credential. |
typeProperties.servicePrincipalId |
object |
The app ID of the service principal used to authenticate |
typeProperties.servicePrincipalKey |
The key of the service principal used to authenticate. |
|
typeProperties.tenant |
object |
The ID of the tenant to which the service principal belongs |
Type
Linked service reference type.
Value | Description |
---|---|
LinkedServiceReference |