getSingle static method

Future<PcoPeopleApp?> getSingle(
  1. String id, {
  2. PcoPeopleAppQuery? query,
})

Will get a single PcoPeopleApp object using a path like this: /people/v2/apps/[id]

Additional options may be specified by using the query argument, but some query options are also available as boolean flags in this function call too.

Implementation

static Future<PcoPeopleApp?> getSingle(
  String id, {
  PcoPeopleAppQuery? query,
}) async {
  query ??= PcoPeopleAppQuery();

  var url = '/people/v2/apps/$id';
  var retval = await PcoCollection.fromApiCall<PcoPeopleApp>(url,
      query: query, apiVersion: kApiVersion);
  return retval.items.isEmpty ? null : retval.items.first;
}