Set user field mapping
Say where one Corma user field takes its value from. A field has one source at a time, so this replaces whatever was configured before rather than adding to it. A configured field cannot return to the connector defaults.
curl -X PUT "https://api.corma.io/v1/user-fields/{id}/mapping" \
-H "x-corma-api-key: $CORMA_OPEN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"mode": "source",
"connectorId": "string",
"expression": "string"
}'Autorisation
x-corma-api-keystringheaderobligatoireColon-separated API key ID and secret:
API_KEY_ID:API_KEY_SECRET
Paramètres
idstringpathobligatoireThe identifier of the user field, as
GET /user-fieldsreturned it.x-corma-idempotency-keystringheaderOptional client-generated key. Reusing the same key with an identical request replays the original response instead of enqueueing a duplicate task.
Corps
Réponse
OK
idstringobligatoireThe identifier of the field —
jobTitlefor a standard field,custom.<key>for one the workspace defined. The manager is one field,manager.labelstringobligatoireThe name of the field, as Corma displays it.
descriptionstring | nullobligatoireOne sentence that says what the field holds. Null for a field the workspace defined.
typeenum<string>obligatoireThe type of value the field holds.
Une des valeurs:stringnumberbooleandatestring[]object[]useroriginenum<string>obligatoireWhether Corma defines the field or the workspace does.
Une des valeurs:standardcustominboundMappablebooleanobligatoireWhether a connector may feed this field. False for the professional email, which matches a person across connectors, and for the fields Corma computes from another one.
defaultSourcesstring[]obligatoireThe connected connectors that write this field in the
defaultmode. Empty when no connector declares a default for it.mappingany ofobligatoireWhere the field takes its value from.
{
"id": "string",
"label": "string",
"description": "string",
"type": "string",
"origin": "standard",
"inboundMappable": true,
"defaultSources": [
"string"
],
"mapping": {
"mode": "default"
}
}