Page History
...
CMR Environments Table
...
CMR Environment
...
Base API URL (through ECHO)
...
Associated URS Environment
...
Operational (OPS)
...
Information on creating EDL tokens can be found at https://urs.
...
...
Acceptance Test (UAT)
...
https://api-test.echo.nasa.gov
...
https://beta.urs.eosdis.nasa.gov
...
Systems Integration Test (SIT)
...
...
https://alpha.urs.eosdis.nasa.gov
...
- Depending on the environment you have chosen, the Base API URL may be different from the example. If so, just replace the purple text with the correct Base API URL that you need. If you are imbedding the token REST messages into a programming language, create an HTTP message and place the same components from the curl example into either the message header or body.
Code Block curl -X POST --header "Content-Type: application/xml" -d "<token><username>sample_username</username><password>sample-password</password><client_id>client_name_of_your_choosing</client_id><user_ip_address>your_origin_ip_address</user_ip_address> <provider>PROV_ID</provider></token>" https://api.echo.nasa.gov/echo-rest/tokens
Another way using curl if you don't want to escape any characters, you can use the "file input" option to create a file that looks like the following:
mytokengenerator.xml
<
token
>
<
username
>sample_username</
username
>
<
password
>sample-password</
password
>
<
client_id
>client_name_of_your_choosing</
client_id
>
<
user_ip_address
>your_origin_ip_address</
user_ip_address
>
<
provider
>PROV_ID</
provider
>
</
token
>
Then, the full curl command looks a little bit different:
curl -X POST --header
"Content-Type: application/xml"
-d
@mytokengenerator
.xml https:
//api-test.echo.nasa.gov/echo-rest/tokens
Again, if using a programming language, just place the curl example parts into the correct http message header or body locations.
A sample response from the curl call is:
<?
xml
version
=
"1.0"
encoding
=
"UTF-8"
?>
<
token
>
<
id
>75E5CEBE-6BBB-2FB5-A613-0368A361D0B6</
id
>
<
username
>sample_username</
username
>
<
client_id
>client_name_of_your_choosing</
client_id
>
<
user_ip_address
>your_origin_ip_address</
user_ip_address
>
<
provider
>PROV_ID</
provider
>
</
token
>
To delete a token execute the following curl command for the environment you have chosen.
curl -X DELETE --header "Content-Type: application/xml" https: //api.echo.nasa.gov/echo-rest/tokens |
Depending on the environment you have chosen, the Base API URL may be different from the example. If so, just replace the purple text with the correct Base API URL that you need. If you are imbedding the token REST messages into a programming language, create an HTTP message and place the same components from the curl example into either the message header or body.
The return code should be a 204, otherwise an error has occurred.
...
/documentation/for_users/user_token