Set a named credential as preferred credential

post

https://EM_HOST:EM_CONSOLE_HTTPS_PORT/em/api/namedCredentials/actions/setPreferredCredential

Sets an existing named credential as preferred for the target type/target instance and set name provided in the payload.

Request

There are no request parameters for this operation.

Supported Media Types
Request Body - application/json ()
Root Schema : schema
Type: object
Schema object to hold Preferred Credential data required in the setPreferredCredential action. credGuid can be passed or credName and credOwner combination in order to find the named credential to set as preferred.
Show Source
Match All
Schema object to hold Preferred Credential data required in the setPreferredCredential action. credGuid can be passed or credName and credOwner combination in order to find the named credential to set as preferred.
Show Source
Nested Schema : PreferredCredentialCommon
Type: object
Common schema object to hold Preferred Credential data
Show Source
Examples

Back to Top

Response

Supported Media Types

200 Response

Preferred credential set successfully
Body ()
Root Schema : PreferredCredential
Type: object
Schema object to hold Preferred Credential data returned from the search action
Show Source
  • Unique identifier for a named credential
    Example: B0FBBE587FD201E2E0537013790A7D03
  • true when preferred credential is configured for given case and link to NC is available. when effective value is there and not configured set as false but NC link is available. If no Preferred set at all then false and no link to NC.
    Example: false
  • links
  • Unique identifier for target type
    Example: DD395385F69A25570431A719EEA45030
Match All
Schema object to hold Preferred Credential data returned from the search action
Show Source
Nested Schema : PreferredCredentialCommon
Type: object
Common schema object to hold Preferred Credential data
Show Source

400 Response

Bad Request
Body ()
Root Schema : ErrorResponse
Type: object
Response sent back in the case of an error
Show Source
  • The status code of the error
    Example: IllegalArgument
  • A descriptive error message
    Example: The argument given is not supported

401 Response

Unauthorized
Body ()
Root Schema : ErrorResponse
Type: object
Response sent back in the case of an error
Show Source
  • The status code of the error
    Example: IllegalArgument
  • A descriptive error message
    Example: The argument given is not supported

403 Response

Forbidden
Body ()
Root Schema : ErrorResponse
Type: object
Response sent back in the case of an error
Show Source
  • The status code of the error
    Example: IllegalArgument
  • A descriptive error message
    Example: The argument given is not supported

409 Response

Duplicate Resource
Body ()
Root Schema : ErrorResponse
Type: object
Response sent back in the case of an error
Show Source
  • The status code of the error
    Example: IllegalArgument
  • A descriptive error message
    Example: The argument given is not supported

500 Response

Internal Server Error
Body ()
Root Schema : ErrorResponse
Type: object
Response sent back in the case of an error
Show Source
  • The status code of the error
    Example: IllegalArgument
  • A descriptive error message
    Example: The argument given is not supported

503 Response

Service Unavailable
Body ()
Root Schema : ErrorResponse
Type: object
Response sent back in the case of an error
Show Source
  • The status code of the error
    Example: IllegalArgument
  • A descriptive error message
    Example: The argument given is not supported
Back to Top