Follow the steps below to create a new Script:
- Go to the Admin Menu and select “Scripts”.
- Create a new Script using the “+ Script” button.
- Grab the value from the Application Key. You’ll need this to initiate a connection to Shotgun.
- Now you can use your Script key to connect to Shotgun. See “Shotgun Methods” in our API documentation to learn more about how to connect to Shotgun with your Script.
Pro tip: If for some reason you need to reset the Application Key of your Script, you’ll need to create a new Shotgun Script entity to do so. First rename your existing Script to something like “[My Script]—OLD”, then delete it. Create a new Script. The reason you need to rename the old one is that Shotgun requires unique names for each Script.
When to set up a new Script
Script actions can be logged. The more fine-grained the use of individual Script keys, the easier it will be for you to track which Script is making changes for debugging. Having separate Scripts is also a good way to track which Scripts will be impacted by changes on your Shotgun site and who maintains the Script.