Truefoundry UI itself shows the instructions to deploy the service using the CLI or UI.So we recommend to first deploy the service using UI and then copy the YAML or Python code generated to deploy programatically. You can also copy the spec / Python code from an existing service and make the changes to deploy your service.
- Deploy using YAML
- Deploy using Python SDK
1
Click on Edit Button on a service

2
Click on Deploy Using YAML button

3
Copy the YAML code and follow the instructions
You will need to install the Truefoundry CLI, login and then execute the 
tfy apply
command to deploy the service.