Hello there,

I would like to automate pipeline/template creation, so I took a look
at the nice documentation at
https://api.gocd.org/current/#template-config. Version of gocd is
17.1.0

Now after playing around a bit with curl I am confused:
* it seems I always need to specify the *exact* version I want to retrieve

Working examples which return JSON
curl -b cookie.jar -H 'Accept: application/vnd.go.cd.v3+json'
https://gocdserver.lan/go/api/admin/templates

curl -b cookie.jar -H 'Accept: application/vnd.go.cd.v4+json'
https://gocd.server.lan/go/api/agents

curl -b cookie.jar -H 'Accept: application/json'
https://gocd.server.lan/go/api/config/materials

Now i I try something like
curl -b cookie.jar -H 'Accept: application/vnd.go.cd.v4+json'
https://gocd.server.lan/go/api/config/materials

or

curl -b cookie.jar -H 'Accept: application/json'
https://gocdserver.lan/go/api/admin/templates

does not work

Is this expected? I tried application/* and */* as well, for materials
this is working, the other objects always return a HTML error-page.

Is this the intended behavior or do I do something wrong?

Best Regards Mirko
--
http://illegalstateexception.blogspot.com/
https://github.com/mfriedenhagen/ (http://osrc.dfm.io/mfriedenhagen)
https://bitbucket.org/mfriedenhagen/

-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to