Targets: REST API changes
Along with the Targets feature, we need to make some major changes to the way our API retrieves information about actions. Targets will allow users to define server credentials as a "target" that can be used across multiple actions, and actions will gain the ability to point to multiple targets at the same time.
What will change?
In addition to collecting action information, other changes include adding and updating actions using the REST API.
The way this works is that the action's JSON will now have the server information in the Targets array.
Here's an example of SFTP transfer action that uses key as an authentication method:
JSON{ "name": "Upload files to 5.75.234.250 by SFTP(Key)", "type": "TRANSFER", "trigger_time": "ON_EVERY_EXECUTION", "input_type": "SCM_REPOSITORY", "local_path": "/", "remote_path": "", "targets": [ { "id": "sftp_target_1", "type": "SSH", "host": "5.75.234.250", "port": "22", "auth": { "method": "SSH_KEY", "username": "sftp-key-0", "key": "$MyKey" } } ] }
Please take note that authentication_mode
has been replaced with indented auth
and the value names were replaced with:
- PASS is now PASSWORD
- PRIVATEKEY, PRIVATEKEYANDPASS are now SSH_KEY
- ENVKEY is now ASSETSKEY
- SAMEASPROXY is now PROXY_CREDENTIALS
- PROXYKEY, CUSTOMPROXYKEY are now PROXYKEY
- NAME is now ID
- SERVER_KEY is now KEY
- ENV_KEY is now ASSET
- CUSTOMPROXYKEY, serverKey are now keyPath

Jarek Dylewski
Customer Support
A journalist and an SEO specialist trying to find himself in the unforgiving world of coders. Gamer, a non-fiction literature fan and obsessive carnivore. Jarek uses his talents to convert the programming lingo into a cohesive and approachable narration.