<p>In the context of the OpenShift 3.7 <a href="https://docs.openshift.com/container-platform/3.6/architecture/service_catalog/index.html" rel="nofollow noreferrer">Service Catalog</a>, what would it look like if I wanted to create Service Instances outside of the OpenShift Console UI?</p>

<p>I.e. from a terminal on my local machine, if I wanted to create an instance of a Service Class available in the Service Catalog (e.g. run and an <a href="https://github.com/ansibleplaybookbundle/ansible-playbook-bundle" rel="nofollow noreferrer">APB</a> available via the <a href="https://github.com/openshift/ansible-service-broker" rel="nofollow noreferrer">Ansible Service Broker</a>) what would the REST resource call look like (assuming there is a REST API available)?</p>

<p>An example using <code>curl</code> would be appreciated.</p>

<p>The assumption is that there is a REST API available for Service Catalog related resources. If this is not true, what is another integration pattern that would satisfy the requirement above? Does the <code>oc</code> CLI tool support Service Catalog commands?</p>

<p>The best examples I can point you to are the ones from <a href="https://github.com/kubernetes-incubator/service-catalog/blob/master/docs/walkthrough.md" rel="nofollow noreferrer">the incubator repo walkthrough</a>.  You'll probably be most interested in the <a href="https://github.com/kubernetes-incubator/service-catalog/blob/master/contrib/examples/walkthrough/ups-broker.yaml" rel="nofollow noreferrer">example ServiceInstance</a> and example <a href="https://github.com/kubernetes-incubator/service-catalog/blob/master/contrib/examples/walkthrough/ups-instance.yaml" rel="nofollow noreferrer">ServiceBinding</a>.</p>

<p>The service-catalog has a normal Kubernetes API server and the resources work like the other resources you're familiar with do.  For example, you could make a new instance of a service in the openshift console and poke around in the API server using:</p>

<pre><code>$ kubectl get serviceinstances
</code></pre>

<p>Note, <code>oc get serviceinstances</code> is another valid form of command to use.</p>

<p>The CLI experience isn't fantastic for <code>kubectl get</code> for these resources yet, but <code>describe</code> works very well.  In a future release of service-catalog the CLI experience for <code>kubectl get</code> will be improved.</p>
