Code samples and procedures for creating workers are provided below.
Event | Sample Code | Create using Platform UI | Using API |
---|---|---|---|
Before downloading artifact in Artifactory | POST ${baseUrl}/worker/api/v1/workers | ||
After downloading artifact in Artifactory | POST ${baseUrl}/worker/api/v1/workers | ||
Before upload request is run in Artifactory | POST ${baseUrl}/worker/api/v1/workers | ||
After create in Artifactory, available to customers with both Artifactory and Xray licenses, when Workers Service moves from Beta to General Availability | POST ${baseUrl}/worker/api/v1/workers | ||
After moving artifact from one repository to another in Artifactory | POST ${baseUrl}/worker/api/v1/workers | ||
After build info has been saved in Artifactory storage | POST ${baseUrl}/worker/api/v1/workers | ||
Runs custom code independent of any events in the JFrog Platform, can create generic event | Execute Worker for Generic Event- POST /worker/api/v1/execute/{workerKey} |