A script to update, for each product variant, the availability flag to a custom attribute (to allow searching by availability)
$ npm install -g sphere-products-availability-sync
$ products-availability-sync --projectKey {PROJECT_KEY} --clientId {CLIENT_ID} --clientSecret {CLIENT_SECRET}
# or for help about command options
$ products-availability-sync