Skip to content
This repository has been archived by the owner on Aug 17, 2021. It is now read-only.

07 Use Web API

Bogdan Marian edited this page Oct 12, 2017 · 2 revisions

This page details how to use Rancher Web API in order to perform CRUD operations against all server resources.
Rancher currently supports 2 API versions: v1 and v2-beta.

More information can be found here (v2-beta) and here (v1).

Fetch Stacks by Environment

  • Web API v2-beta
    curl -u 74FF92AEC4691F7D8AF4:Kyw1kfNSJZXrSk8nK1f93P8bhxNMaPDEGEpsRPcT http://192.168.99.103:8080/v2-beta/projects/1a7/stacks
  • Web API v1
    curl -u 74FF92AEC4691F7D8AF4:Kyw1kfNSJZXrSk8nK1f93P8bhxNMaPDEGEpsRPcT http://192.168.99.103:8080/v1/projects/1a7/environments

Fetch Stack

  • Web API v2-beta
    curl -u 74FF92AEC4691F7D8AF4:Kyw1kfNSJZXrSk8nK1f93P8bhxNMaPDEGEpsRPcT http://192.168.99.103:8080/v2-beta/projects/1a7/stacks/1st23
  • Web API v1
    curl -u 74FF92AEC4691F7D8AF4:Kyw1kfNSJZXrSk8nK1f93P8bhxNMaPDEGEpsRPcT http://192.168.99.103:8080/v1/projects/1a7/environments/1st23
Clone this wiki locally