I am trying to add variables in the newly created project using Rest API. Before that I want to create a project using the API which I unable to create using the below playbook. The same is happening with curl command. Is there other way I add the variables ( project > variables > project/project templates) using API?
hosts: localhost
tasks:
- name: view all the octopus projects.
uri:
url: http://{ip-address}/api
API_key: {API KEY}
force_basic_auth: yes
method: POST
status_code: 200
body:
create-project: name=newProj projectgroup=nova environment=Nova2
register: p
- debug: var=p