I have a website, and want to use the Google Analytics API to give me data that only includes visits with a specific goal completion (say goal 2). I'm trying to use the ga:goal(2)Completions metric in a segment to get this data like this:
segment=dynamic::ga:goal(2)Completions!=0
However, whenever I try this in the Query Explorer I'm told this is an invalid segment value. I don't see goal(n)Completions as a disallowed metric for use in segments in the documentation (https://developers.google.com/analytics/devguides/reporting/core/v3/reference#segment), so what's the problem here? Is there a different way to get this data segment?