google-apigoogle-genomics

Google Genomics API Callsets Search "Unknown field name: datasetIds"


I've been using the Google Genomics API for about a day now. I've successfully called many of the APIs like Datasets.list, Datasets.get, and even Readsets.search but I'm having a problem with the Callsets.search.

I'm making POST request to:

POST https://www.googleapis.com/genomics/v1beta/callsets/search?key=MY_KEY_HERE

And my request body is:

{
    "datasetIds" : [
        "376902546192"
    ]
}

But the response I'm getting back is:

{
    "error" : { 
        "errors": [ 
            { 
                "domain": "global", 
                "reason": "invalid", 
                "message": "Unknown field name: datasetIds", 
                "locationType": "other", 
                "location": "" 
            } 
        ], 
        "code": 400, 
        "message": "Unknown field name: datasetIds" 
    } 
}

According to the documentation: https://developers.google.com/genomics/v1beta/reference/callsets/search datasetIds is a perfectly valid parameter.

The crazy thing that's perplexing me is this identical request works just fine on the readsets/search endpoint but not the callsets/search endpoint? I'm almost wondering if it's a bug in the API. Can anyone help?


Solution

  • Received this from Google:

    The variants and callsets APIs just went through some breaking changes so that they'll be compliant with GA4GH v0.5 when they go fully public.

    All breaking changes should be done now - and I'll try to get all the docs and code samples updated today or tomorrow.

    Until then, you can see the real parameters in the API explorer (it can't lie :) - in this case, the datasetId field has now changed to "variantSetIds" (still using that same value, just a rename)