{"id":16768560,"url":"https://github.com/redjanym/pushover-php","last_synced_at":"2025-03-16T13:24:23.575Z","repository":{"id":62534243,"uuid":"163107622","full_name":"redjanym/pushover-php","owner":"redjanym","description":"PHP SDK(not official) for the pushover.net services","archived":false,"fork":false,"pushed_at":"2019-01-26T10:17:35.000Z","size":21,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-11T16:12:20.919Z","etag":null,"topics":["api","php","pushover","sdk"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/redjanym.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-12-25T19:45:16.000Z","updated_at":"2019-01-17T09:02:44.000Z","dependencies_parsed_at":"2022-11-02T15:00:27.815Z","dependency_job_id":null,"html_url":"https://github.com/redjanym/pushover-php","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/redjanym%2Fpushover-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/redjanym%2Fpushover-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/redjanym%2Fpushover-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/redjanym%2Fpushover-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/redjanym","download_url":"https://codeload.github.com/redjanym/pushover-php/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243873263,"owners_count":20361645,"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":["api","php","pushover","sdk"],"created_at":"2024-10-13T06:11:54.891Z","updated_at":"2025-03-16T13:24:23.547Z","avatar_url":"https://github.com/redjanym.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pushover-php\n\nPHP SDK(not official) for the pushover.net API\n\n**Installation**\n\n* Use composer:\n\n```bash\ncomposer require redjanym/pushover-php \"dev-master\"\n```\n\n* Download and include file:\n\nDownload the repository, unzip the files and require ```Pushover.php```\n\n```php\ninclude \"path/to/Pushover.php\";\n```\n\n**Usage**\n\nThe class Pushover.php is composed of several setter methods to provide information about the message to send like ```title```, ```message```, ```url``` etc and access different API endpoints like sending message, validate user, work with receipts and more.\nIn this step we assume you have already setup your account in Pushover and are in possession of the APP anf USER keys.\n\n**Example**\n\nSending a simple message.\n\n```php\n$pushOver = new Pushover(\"YOUR_APP_TOKEN\", \"YOUR_USER_KEY\");\n\n$pushOver\n    -\u003esetTitle(\"Test title\")\n    -\u003esetMessage('Test message')\n;\n\n$pushOver-\u003esend();\n\nvar_dump($pushOver-\u003egetResponse());\n```\n\nMore examples are available in the [examples directory](examples/)\n. Be sure to add your config keys into the ```config.php``` file.\n\n**Symfony Framework**\n\nAfter installing the library via *composer* you can define the class as a service.\n\nFirst create two parameters to store your token and key.\n\n```yaml\nparameters:\n    pushover_app_token: \"YOUR_APP_TOKEN\"\n    pushover_user_key: \"YOUR_USER_KEY\"\n```\n\nThen declare service for Symfony 2-4:\n\n```yaml\nservice:\n...................\n    app.redjanym_pushover:\n        class: Pushover\n        arguments: [\"%pushover_app_token%\", \"%pushover_user_key%\"]\n```\n\nOr by using AutoWiring:\n\n```yaml\nservice:\n...................\n    Pushover:\n        arguments: \n            $pushoverAppToken: \"%pushover_app_token%\"\n            $pushoverUserKey: \"%pushover_user_key%\"\n ```\n \n Usage is the same as before but in Symfony yu need to get the service first.\n \n ```php\n $pushOver = $this-\u003eget(\"app.redjanym_pushover\");\n $pushOver\n     -\u003esetTitle(\"Test title\")\n     -\u003esetMessage('Test message')\n ;\n \n $pushOver-\u003esend();\n \n var_dump($pushOver-\u003egetResponse());\n ```\n\n**Having issues? Not receiving notifications?**\n\nBe sure to have create the two environment variables described above and/or check the response value of the requests sent in Pushover\n\n**To do**\n\nAdd support for ```attachments```.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fredjanym%2Fpushover-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fredjanym%2Fpushover-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fredjanym%2Fpushover-php/lists"}