Creating this topic on behalf of Maxwell Carey (mcarey@ucar.edu). Here's an email he sent the CMR client developer list:

 

I'd like to create a tag as described in the documentation here: https://cmr.earthdata.nasa.gov/search/site/search_api_docs.html#tagging

I managed to create an ECHO token but when I try to create a tag, I get a 401 Unauthorized response:

$ cat tag_generator.json 
{
  "namespace": "edu.ucar.climatedataguide",
  "value": "test",
  "originator-id": "mcarey"
 }
$ curl -XPOST -i -H "Content-Type: application/json" -H "Echo-Token: XXXXX" https://cmr.earthdata.nasa.gov/search/tags -d @tag_generator.json
HTTP/1.1 401 Unauthorized
Date: Fri, 08 Jan 2016 20:58:41 GMT
Content-Type: application/json
Access-Control-Allow-Origin: *
Content-Length: 58
Server: Jetty(9.2.z-SNAPSHOT)

{"errors":["You do not have permission to create a tag."]}


(Actual ECHO token redacted above.) How do I get permission to create tags in CMR? The documentation says "Access to tags is granted through the TAG_ACL system object identity. Users can only create, update, or delete a tag if they are granted the appropriate permission in ECHO," but I can't figure out where/how to set permissions in ECHO.

  • No labels

3 Comments

  1. user-7b92a

    Our CMR Operations team can give you permission to create tags if you need it. We're going to be working to rewrite tags very soon to change how they work. It may be better to wait until after we've made some of these changes first. Before we give you access we'd like to understand your use case. Could you describe how you're going to use tags in the CMR? 

  2. The following use case was laid out to us,

    ''I'm working on a project to ingest dataset metadata from various sources into NCAR's Climate Data Guide (https://climatedataguide.ucar.edu/). We would use the tagging to group the records we're interested in so that we could ingest them with a single HTTP request instead of having to make a separate request for each record."

    Clarification: You are talking about searching CMR for a group of records to ingest into your application?

    user-7b92a - I believe in order to create such a tag you would need to develop a query that would match the inventory.

     

    In that case, unless the use case is ease-of-use for your query I'm not sure of the gain to be had.

  3. user-7b92a

    Note the discussion here was had offline because of permissions issues with the Forum which are now fixed. The gist of the discussion is that he would like to query by multiple ids at a time. There was a mistake on his part in constructing the URL. After fixing that he was able to retrieve multiple at the same time. There's no need for tagging for this use case.