Skip to content

Commit c5144ee

Browse files
committed
clarify curl vs cf curl [#162615959]
1 parent f7ce698 commit c5144ee

File tree

1 file changed

+7
-13
lines changed

1 file changed

+7
-13
lines changed

managing-cf/app-event.html.md.erb

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,20 +10,14 @@ This topic explains how to query the Cloud Controller API (CAPI) to retrieve cur
1010

1111
## <a id='target'></a> Target and Log In
1212

13-
To perform the procedures in this topic, you must target the endpoint of your Cloud Controller and log in. If you do not have the cf CLI installed, see the [Installing the cf CLI](../../cf-cli/install-go-cli.html) topic.
13+
To perform the procedures in this topic, you must authenticate to your Cloud Controller. There are two ways of doing this:
1414

15-
There are two ways to target your Cloud Controller endpoint. You can run the following `curl` command to target the endpoint and log in:
16-
<pre class='terminal'>
17-
$ curl "https://app-usage.YOUR-SYSTEM-DOMAIN/system_report/app_usages" -k -v \
18-
-H "authorization: `cf oauth-token`"
19-
</pre>
20-
21-
You can also use `cf curl` to retrieve information. To use `cf curl`, do the following:
15+
* Run `curl` commands that include the Cloud Controller endpoint and pass in your authorization token each time with the `-H` flag.
2216

23-
1. Target the endpoint of your Cloud Controller:
17+
* Run `cf curl` commands without including the endpoint or token. To do this, you must first use the Cloud Controller Command-Line Interface (cf CLI) to target the endpoint of your Cloud Controller and log in, as follows:
18+
1. Target the endpoint of your Cloud Controller:
2419
<pre class='terminal'>$ cf api api.YOUR-SYSTEM-DOMAIN</pre>
25-
26-
1. Log in as admin or as an Org Manager or Org Auditor for the org you want to obtain information about.
20+
1. Log in as admin or as an Org Manager or Org Auditor for the org you want to obtain information about.
2721
<pre class='terminal'>
2822
$ cf login -u admin
2923
API endpoint: api.YOUR-SYSTEM-DOMAIN
@@ -38,8 +32,8 @@ You can also use `cf curl` to retrieve information. To use `cf curl`, do the fol
3832
User: user<span>@</span>example.com
3933
Org: YOUR-ORG
4034
Space: development
41-
</pre>
42-
35+
</pre>
36+
If you do not have the cf CLI installed, see the [Installing the cf CLI](../../cf-cli/install-go-cli.html) topic
4337

4438
## <a id='obtain_apps'></a> Obtain App Information
4539

0 commit comments

Comments
 (0)