{"id":15458022,"url":"https://github.com/websoftwares/avin","last_synced_at":"2025-10-09T00:20:38.026Z","repository":{"id":57079179,"uuid":"11583037","full_name":"websoftwares/Avin","owner":"websoftwares","description":"Client for interacting with the avin.cc JSON RESTful api.","archived":false,"fork":false,"pushed_at":"2013-07-30T14:29:19.000Z","size":128,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-10-12T13:21:39.541Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/websoftwares.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-07-22T14:15:26.000Z","updated_at":"2019-08-13T15:24:04.000Z","dependencies_parsed_at":"2022-08-24T13:10:46.280Z","dependency_job_id":null,"html_url":"https://github.com/websoftwares/Avin","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/websoftwares%2FAvin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/websoftwares%2FAvin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/websoftwares%2FAvin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/websoftwares%2FAvin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/websoftwares","download_url":"https://codeload.github.com/websoftwares/Avin/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246635987,"owners_count":20809333,"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":[],"created_at":"2024-10-01T22:57:24.959Z","updated_at":"2025-10-09T00:20:33.007Z","avatar_url":"https://github.com/websoftwares.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Avin\n\nClient for interacting with the [avin.cc](http://www.avin.cc/api-documentation/ \"avin.cc\") JSON RESTful api.\n\n[![Build Status](https://api.travis-ci.org/websoftwares/Avin.png)](https://travis-ci.org/websoftwares/Avin)\n\n## Documentation\nWe encourage you to read the [documentation](http://www.avin.cc/api-documentation/ \"avin.cc\") carefully before proceeding.\n\n## Api Key\nThe AVIN API requires a developer key which you can ask avin.cc using this email address: info@avin.cc.\n\n## Installing via Composer (recommended)\n\nInstall composer in your project:\n```\ncurl -s http://getcomposer.org/installer | php\n```\n\nCreate a composer.json file in your project root:\n```\n{\n    \"require\": {\n        \"websoftwares/avin\": \"dev-master\"\n    }\n}\n```\n\nInstall via composer\n```\nphp composer.phar install\n```\n\n## Usage\nBelow u find a list with available methods.\n\n## GetWineByAvin\nGets a wine by Avin.\n\n```php\nuse Websoftwares\\AvinClient, Websoftwares\\Avin;\n\n$avin = new Avin(new AvinClient('123456789YourApiKey'));\n$avin-\u003eGetWineByAvin('AVIN0123456789012');\n\n```\n\n## GetWinesByName\nGets wine by name.\n\n```php\nuse Websoftwares\\AvinClient, Websoftwares\\Avin;\n\n$avin = new Avin(new AvinClient('123456789YourApiKey'));\n$avin-\u003eGetWinesByName('Era');\n\n```\n\n## GetCountries\nGets a list of countries.\n\n```php\nuse Websoftwares\\AvinClient, Websoftwares\\Avin;\n\n$avin = new Avin(new AvinClient('123456789YourApiKey'));\n$avin-\u003eGetCountries();\n\n```\n\n## GetWineTypes\nGets a list of wine types.\n\n```php\nuse Websoftwares\\AvinClient, Websoftwares\\Avin;\n\n$avin = new Avin(new AvinClient('123456789YourApiKey'));\n$avin-\u003eGetWineTypes();\n\n```\n\n## GetProducerByID\nGets a producer by id.\n\n```php\nuse Websoftwares\\AvinClient, Websoftwares\\Avin;\n\n$avin = new Avin(new AvinClient('123456789YourApiKey'));\n$avin-\u003eGetProducerByID(12345);\n\n```\n\n## GetProducerByName\nGets a producer by name.\n\n```php\nuse Websoftwares\\AvinClient, Websoftwares\\Avin;\n\n$avin = new Avin(new AvinClient('123456789YourApiKey'));\n$avin-\u003eGetProducerByName('Producer sample name');\n\n```\n\n## setFilter\nPlease read the [documentation](http://www.avin.cc/api-documentation/ \"avin.cc\") for a complete list of available filters.\n\n```php\nuse Websoftwares\\AvinClient, Websoftwares\\Avin;\n\n$avin = new Avin(new AvinClient('123456789YourApiKey'));\n\n$avin\n\t-\u003esetFilter('vintage', 2003)\n    -\u003esetFilter('country', 620)\n    -\u003esetFilter('type', '1')\n    -\u003esetFilter('producer', 'Cortes de Cima')\n    -\u003eGetWineByAvin('AVIN6452997073019');\n\n```\n\n## Error messages\nUse try/catch block to get error messages.\n\n```php\nuse Websoftwares\\AvinClient,\n\tWebsoftwares\\Avin,\n\tWebsoftwares\\AvinException;\n\ntry {\n\t$avin = new Avin(new AvinClient('123456789YourApiKey'));\n\t$avin-\u003eGetWinesByName('Era');\n} catch (AvinException $e) {\n\techo $e-\u003egetMessage();\n}\n\n```\n\n## Testing\nIn the tests folder u can find several tests for online and offline.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebsoftwares%2Favin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwebsoftwares%2Favin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebsoftwares%2Favin/lists"}