Skip to content

Instantly share code, notes, and snippets.

@CypherpunkSamurai
Created October 13, 2021 16:35
Show Gist options
  • Select an option

  • Save CypherpunkSamurai/7d6255ca6bdd96b4103c0ebc1595651b to your computer and use it in GitHub Desktop.

Select an option

Save CypherpunkSamurai/7d6255ca6bdd96b4103c0ebc1595651b to your computer and use it in GitHub Desktop.
Heroku API

Heroku

  • Apps
curl 'https://api.heroku.com/users/~/apps' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.cedar-acm' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Range: name ..; order=asc, max=1000' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • Get App Data
curl 'https://api.heroku.com/teams/apps/xaria2-test' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.cedar-acm' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'If-None-Match: "a75764db8991c1d86c22dbf2b50d413b"' -H 'TE: trailers'
  • App Rename
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7' -X PATCH -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.cedar-acm' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Content-Type: application/json; charset=utf-8' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers' --data-raw '{"name":"xaria2-test2","maintenance":false}'
  • App Formation
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/formation' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'If-None-Match: "f72bf4ef39c2acc9335499d71c4d648e"' -H 'TE: trailers'
  • App Builds
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/builds' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.pipelines' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Range: created_at ..; order=desc' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Transfer
curl 'https://api.heroku.com/account/app-transfers' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Release
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/releases' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.pipelines' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Range: version ..; order=desc' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Builds
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/builds' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.pipelines' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Range: created_at ..; order=desc' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Montitors
curl 'https://api.metrics.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/formation/web/monitors' -X OPTIONS -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: */*' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Access-Control-Request-Method: GET' -H 'Access-Control-Request-Headers: authorization,x-origin' -H 'Referer: https://dashboard.heroku.com/' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1'
  • App Workers (Scale)
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/formation/b19381ae-cc59-43cb-8ab2-83ac98f729a4' -X PATCH -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Content-Type: application/json; charset=utf-8' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers' --data-raw '{"quantity":0,"size":"Free","type":"web"}'
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/formation/b19381ae-cc59-43cb-8ab2-83ac98f729a4' -X PATCH -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Content-Type: application/json; charset=utf-8' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' --data-raw '{"quantity":1,"size":"Free","type":"web"}'
  • App Addon Attachments
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/addon-attachments' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Legacy-Ids: true' -H 'Accept-Inclusion: config_vars' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Buildpacks
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/buildpack-installations' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'If-None-Match: "f72bf4ef39c2acc9335499d71c4d648e"' -H 'TE: trailers'
  • App Config Vars
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/config-vars' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Add Config Var
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/config-vars' -X PATCH -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Content-Type: application/json' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers' --data-raw '{"XUSER":"admin"}'
  • App Delete Config Var
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/config-vars' -X PATCH -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Content-Type: application/json' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers' --data-raw '{"KEY":null}'
  • App SNI Endpoints
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/sni-endpoints' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.allow_multiple_sni_endpoints' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Range: id ..; order=asc, max=1000' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Domains
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/domains' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.allow_multiple_sni_endpoints' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Range: hostname ..; order=asc, max=1000' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers'
  • App Logs
curl 'https://api.heroku.com/apps/72e11ef0-92f9-4655-9be9-d1e45a810bf7/log-sessions' -X POST -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Content-Type: application/json; charset=utf-8' -H 'X-Origin: https://dashboard.heroku.com' -H 'X-Heroku-Requester: dashboard' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers' --data-raw '{"lines":10,"tail":true}'
  • App State
curl 'https://particleboard.heroku.com/app-states' -X POST -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/json, text/javascript, */*; q=0.01' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dashboard.heroku.com/' -H 'Content-Type: application/json; charset=utf-8' -H 'Authorization: Bearer API_KEY' -H 'Origin: https://dashboard.heroku.com' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Sec-GPC: 1' -H 'TE: trailers' --data-raw '{"apps":"xaria2-test,xaria2crypt"}'
  • Acoc
curl 'https://api.heroku.com/account' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:93.0) Gecko/20100101 Firefox/93.0' -H 'Accept: application/vnd.heroku+json; version=3.with_vaas_and_msa_info' -H 'Accept-Language: en-US,en;q=0.5' -H 'Authorization: Bearer API_KEY'

Ref

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment