{"id":18720768,"url":"https://github.com/lee-to/laravel-airtable","last_synced_at":"2025-07-04T13:06:48.594Z","repository":{"id":57013473,"uuid":"278614289","full_name":"lee-to/laravel-airtable","owner":"lee-to","description":"AirTable API client for Laravel","archived":false,"fork":false,"pushed_at":"2022-12-01T10:22:33.000Z","size":8,"stargazers_count":5,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-12T14:25:15.852Z","etag":null,"topics":["airtable","airtable-api","laravel","php","php-airtable"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lee-to.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-07-10T11:14:37.000Z","updated_at":"2023-11-22T21:30:24.000Z","dependencies_parsed_at":"2023-01-22T09:45:19.427Z","dependency_job_id":null,"html_url":"https://github.com/lee-to/laravel-airtable","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/lee-to/laravel-airtable","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lee-to%2Flaravel-airtable","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lee-to%2Flaravel-airtable/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lee-to%2Flaravel-airtable/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lee-to%2Flaravel-airtable/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lee-to","download_url":"https://codeload.github.com/lee-to/laravel-airtable/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lee-to%2Flaravel-airtable/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263548654,"owners_count":23478808,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["airtable","airtable-api","laravel","php","php-airtable"],"created_at":"2024-11-07T13:32:34.278Z","updated_at":"2025-07-04T13:06:48.564Z","avatar_url":"https://github.com/lee-to.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AirTable API client for Laravel\n\nAirTable API client for Laravel. Used library [AirTable PHP)(https://github.com/lee-to/php-airtable)\n\n## Installation\n\nThe AirTable Client Laravel can be installed with [Composer](https://getcomposer.org/). Run this command:\n\n```sh\ncomposer require lee-to/laravel-airtable\n```\n\n## Publish provider\n\n```sh\nphp artisan vendor:publish --provider=\"AirTableLaravel\\Providers\\AirTableServiceProvider\"\n```\n\n## .env:\n\n```bash\nAIRTABLE_TOKEN=\nAIRTABLE_BASE=\nAIRTABLE_TABLE=\n```\n\n## config/app.php:\n\nAdd alias\n\n```bash\n'aliases' =\u003e [\n        ...\n        \n        'AirTable' =\u003e \\AirTableLaravel\\Facades\\AirTableFacade::class,\n    ],\n```\n\nAdd provider\n\n```bash\n'providers' =\u003e [\n\n        ...\n\n        AirTableLaravel\\Providers\\AirTableServiceProvider::class,\n    ],\n```\n\n## Usage\n\nGet token and base from [AirTable Account](http://airtable.com/account) and [AirTable API](http://airtable.com/api)\n\n### Import.\n```php\nuse Airtable;\n```\n\n#### Get records from that table\n- List table records\n\n``` php\nAirtable::table('table_name')-\u003eget();\n```\n\nOr use default table\n\n``` php\nAirtable::get();\n```\n\nOr get all records\n\n``` php\nAirtable::all();\n```\n\n#### Get one record from table.\n``` php\nAirtable::table('table_name')-\u003efind('ID');\n```\n\nOr use default table\n\n``` php\nAirtable::find('ID');\n```\n\n#### Filter records\n- First argument is the column name\n- Second argument is the operator or the value if you want to use equal '=' as an operator.\n- Third argument is the value of the filter\n``` php\nAirtable::table('table_name')-\u003ewhere(\"column\", \"operator\", \"value\")-\u003eget();\n```\n\n#### Sort records\n- First argument is the column name\n- Second argument is direction.\n\n``` php\nAirtable::table('table_name')-\u003eorderBy(\"column\", \"direction\")-\u003eget();\n```\n\n#### Fields\n- Only data for fields whose names are in this list will be included in the result. If you don't need every field, you can use this parameter to reduce the amount of data transferred\n\n``` php\nAirtable::table('table_name')-\u003efields([\"Column1\", \"Column2\"])-\u003eget();\n```\n\nOr\n\n``` php\nAirtable::all([\"Column1\", \"Column2\"]);\n```\n\n#### Max records \n- The maximum total number of records that will be returned in your requests. If this value is larger than pageSize (which is 100 by default), you may have to load multiple pages to reach this total.\n\n``` php\nAirtable::table('table_name')-\u003elimit(5)-\u003eget();\n```\n\n#### Update \n- Update one record\n\n``` php\nAirtable::table('table_name')-\u003eupdate('ID', [\"Column1\" =\u003e \"Value\"]);\n```\n\nOR \n\n``` php\nforeach(Airtable::get() as $record) {\n    $record-\u003eupdate([\"Column1\" =\u003e \"Value\"]);\n}\n```\n\n#### Update or create\n- Update or create record\n\n``` php\nAirtable::table('table_name')-\u003eupdateOrCreate('ID', [\"Column1\" =\u003e \"Value\"]);\n```\n\n#### Create\n- Create a new record\n\n``` php\nAirtable::table('table_name')-\u003ecreate([\"Column1\" =\u003e \"Value\"]);\n```\n\n#### First or create\n- Create a new record or find first match\n\n``` php\nAirtable::table('table_name')-\u003efirstOrCreate([\"Column1\" =\u003e \"Value\"]);\n```\n\n#### Delete\n- Delete one record\n\n``` php\nAirtable::table('table_name')-\u003edelete('ID');\n```\n\nOR \n\n``` php\nforeach(Airtable::table('table_name')-\u003eget() as $record) {\n    $deleted = $record-\u003edelete();\n    \n    $deleted-\u003eisDeleted(); // Check is deleted or not\n}\n```\n\n#### Get fields of record\n\n``` php\nforeach(Airtable::table('table_name')-\u003eget() as $record) {\n    $record-\u003egetId(); // ID \n    \n    $record-\u003eCOLUMN1; // Any fields in table \n}\n```\n\n## Contributing\n\nPlease see [CONTRIBUTING](CONTRIBUTING.md) for details.\n\n## Credits\n\n- [Danil Shutsky](https://github.com/lee-to)\n- [All Contributors](../../contributors)\n\n## License\n\nThe MIT License (MIT). Please see [License File](LICENSE.md) for more information.\n\n## Security\n\nIf you have found a security issue, please contact the maintainers directly at [leetodev@ya.ru](mailto:leetodev@ya.ru).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flee-to%2Flaravel-airtable","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flee-to%2Flaravel-airtable","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flee-to%2Flaravel-airtable/lists"}