Skip to content

Remap all source files of a library at application level

Request

Remaps ALL source files currently mapped to the given originalLibrary to a target library for the specified application(s). The server resolves the library's source files on its own (no sourceFileUuids required). Runs asynchronously and returns 202 Accepted with async process status. Requires exactly one of: targetLibraryUuid OR matchSuggestionId.

Security
bearer-key
Path
orgUuidstringrequired

org UUID (from the Mend App: Administration General > Organization UUID).

Bodyapplication/jsonrequired
applicationUuidsArray of strings
targetLibraryUuidstring(Target Library UUID)

The UUID of the library to which source files should be remapped. Exactly one of targetLibraryUuid or matchSuggestionId must be provided

Example:"123e4567-e89b-12d3-a456-426655440000"
matchSuggestionIdstring(Target Library Id)

The Id of the library to which source files should be remapped. Exactly one of targetLibraryUuid or matchSuggestionId must be provided

Example:"ZWJlMTZhZjYtMmE2YS00MWQ1LWFiNTQtYWQ3YWE3OWZhNzFl"
sourceFileUuidsArray of strings
commentstring(Comment)

Optional user comment explaining the reason for this remapping action

sendEmailNotificationboolean(Send Email Notification)

Whether to send email notification upon completion of the remapping operation

Example:true
originalLibraryUuidstring(Original Library UUID)

When set (remap-all-by-library), the server resolves all source files currently mapped to this library on its own; sourceFileUuids is ignored.

Example:"123e4567-e89b-12d3-a456-426655440000"
POST
/api/v3.0/orgs/{orgUuid}/applications/dependencies/sourceFiles/remapping/by-library
{ "applicationUuids": [ "123e4567-e89b-12d3-a456-426655440000" ], "targetLibraryUuid": "123e4567-e89b-12d3-a456-426655440000", "matchSuggestionId": "ZWJlMTZhZjYtMmE2YS00MWQ1LWFiNTQtYWQ3YWE3OWZhNzFl", "sourceFileUuids": [ "123e4567-e89b-12d3-a456-426655440000" ], "comment": "string", "sendEmailNotification": true, "originalLibraryUuid": "123e4567-e89b-12d3-a456-426655440000" }

Responses

Remapping job accepted and initiated

Bodyapplication/json
uuidstring(Process UUID)

The unique identifier of the async process

Example:"caf69794-9882-4b55-82db-6b6da4fe2a92"
statusstring(Process Status)

The current status of the async process

Enum:"PENDING""IN_PROGRESS""FAILED""FAILURE""SUCCESS"
Example:"PENDING"
userEmailstring(User Email)

Email of the user who initiated the process

Example:"user@example.com"
requestTokenstring(Request Token)

Short token for tracking the request

Example:"2cd6a43b"
Response
{ "uuid": "caf69794-9882-4b55-82db-6b6da4fe2a92", "status": "PENDING", "userEmail": "user@example.com", "requestToken": "2cd6a43b" }