> Markdown versions of all pages of this connector library are available by appending `.md` to the page URL. For the full index of connectors, see [llms.txt](https://connectors.appmixer.com/llms.txt).

# appmixer.shopify.customers.FindCustomers

- Component: `appmixer.shopify.customers.FindCustomers`
- Kind: Action
- Version: 1.0.0
- Visibility: Public
- Connector: [appmixer.shopify 4.1.0](https://connectors.appmixer.com/connector/appmixer.shopify/4.1.0.md)
- Component page: <https://connectors.appmixer.com/connector/appmixer.shopify/4.1.0/component/appmixer.shopify.customers.FindCustomers>

Find customers by a search query and filters. Returns up to 250 customers.

## Input ports

### Port `in`

| Field | Type | Description |
| --- | --- | --- |
| Search Query (`query`) | text | Shopify customer search syntax, for example "Jane", "country:Canada", "orders_count:>2" or "email:*@example.com". Leave empty to get all customers. Combined with the filters below. |
| Email (`email`) | text | Only customers with this email address. |
| Phone (`phone`) | text | Only customers with this phone number, for example +16135551111. |
| Tag (`tag`) | text | Only customers with this tag. |
| Created After (`createdAtMin`) | date-time | Only customers created at or after this time. |
| Updated After (`updatedAtMin`) | date-time | Only customers updated at or after this time. |
| Sort By (`sort`) | select | Order of the results. |
| Output Type (`outputType`) | select | Choose whether you want to receive the result set as one complete list, or first item only or one item at a time or stream the items to a file. |

## Output ports

### Port `out`

Variables are loaded dynamically from `/component/appmixer/shopify/customers/FindCustomers?outPort=out&ignoreAuth=true`.

### Port `notFound`

_No fields defined for this port._

## Full metadata (component.json)

```json
{
  "name": "appmixer.shopify.customers.FindCustomers",
  "description": "Find customers by a search query and filters. Returns up to 250 customers.",
  "author": "Jimoh Damilola <jimoh@client.io>",
  "private": false,
  "auth": {
    "service": "appmixer:shopify",
    "scope": [
      "read_customers",
      "read_orders"
    ]
  },
  "quota": {
    "manager": "appmixer:shopify",
    "resources": "requests",
    "scope": {
      "userId": "{{userId}}"
    }
  },
  "inPorts": [
    {
      "name": "in",
      "schema": {
        "type": "object",
        "properties": {
          "query": {
            "type": "string",
            "maxLength": 16384
          },
          "email": {
            "type": "string"
          },
          "phone": {
            "type": "string"
          },
          "tag": {
            "type": "string"
          },
          "createdAtMin": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAtMin": {
            "type": "string",
            "format": "date-time"
          },
          "sort": {
            "type": "string"
          },
          "outputType": {
            "type": "string"
          }
        }
      },
      "inspector": {
        "inputs": {
          "query": {
            "type": "text",
            "label": "Search Query",
            "index": 0,
            "tooltip": "Shopify customer search syntax, for example \"Jane\", \"country:Canada\", \"orders_count:>2\" or \"email:*@example.com\". Leave empty to get all customers. Combined with the filters below."
          },
          "email": {
            "type": "text",
            "label": "Email",
            "index": 1,
            "tooltip": "Only customers with this email address."
          },
          "phone": {
            "type": "text",
            "label": "Phone",
            "index": 2,
            "tooltip": "Only customers with this phone number, for example +16135551111."
          },
          "tag": {
            "type": "text",
            "label": "Tag",
            "index": 3,
            "tooltip": "Only customers with this tag."
          },
          "createdAtMin": {
            "type": "date-time",
            "label": "Created After",
            "index": 4,
            "tooltip": "Only customers created at or after this time."
          },
          "updatedAtMin": {
            "type": "date-time",
            "label": "Updated After",
            "index": 5,
            "tooltip": "Only customers updated at or after this time."
          },
          "sort": {
            "type": "select",
            "label": "Sort By",
            "index": 6,
            "defaultValue": "UPDATED_AT_DESC",
            "tooltip": "Order of the results.",
            "options": [
              {
                "label": "Last updated first",
                "value": "UPDATED_AT_DESC"
              },
              {
                "label": "Least recently updated first",
                "value": "UPDATED_AT_ASC"
              },
              {
                "label": "Newest first",
                "value": "CREATED_AT_DESC"
              },
              {
                "label": "Oldest first",
                "value": "CREATED_AT_ASC"
              },
              {
                "label": "Name A–Z",
                "value": "NAME_ASC"
              },
              {
                "label": "Name Z–A",
                "value": "NAME_DESC"
              },
              {
                "label": "Relevance to the search query",
                "value": "RELEVANCE"
              }
            ]
          },
          "outputType": {
            "type": "select",
            "label": "Output Type",
            "index": 7,
            "defaultValue": "array",
            "tooltip": "Choose whether you want to receive the result set as one complete list, or first item only or one item at a time or stream the items to a file.",
            "options": [
              {
                "label": "First Item Only",
                "value": "first"
              },
              {
                "label": "All items at once",
                "value": "array"
              },
              {
                "label": "One item at a time",
                "value": "object"
              },
              {
                "label": "Store to CSV file",
                "value": "file"
              }
            ]
          }
        }
      }
    }
  ],
  "outPorts": [
    {
      "name": "out",
      "source": {
        "url": "/component/appmixer/shopify/customers/FindCustomers?outPort=out&ignoreAuth=true",
        "data": {
          "properties": {
            "generateOutputPortOptions": true
          },
          "messages": {
            "in/outputType": "inputs/in/outputType"
          }
        }
      }
    },
    {
      "name": "notFound"
    }
  ],
  "icon": "(data URI omitted)"
}
```
