mastodon/config
Eugen Rochko 4b94e9c65e
Improve payload format of Web Push API now that it's open (#7521)
> Good lord what is happening in there

Previously the contents of the Web Push API payloads closely resembled the structure of JavaScript's [Notification](https://developer.mozilla.org/en-US/docs/Web/API/Notification). But now that the API is open to non-browser apps, and given that there is no required coupling between contents of the payload and a Notification object, here is how I changed the payload:

```json
{ 
  "access_token": "...",
  "preferred_locale": "en",
  "notification_id": "12345",
  "notification_type": "follow",
  "title": "So and so followed you",
  "body": "This is my bio",
  "icon": "https://example.com/avatar.png"
}
```

The title, body and icon attributes are included as a fallback so you can construct a minimal notification if you cannot perform a network request to the API to get more data.
2018-05-19 14:46:47 +02:00
..
environments Add support for separate Redis for cache (#7272) 2018-04-27 01:37:59 +02:00
initializers User agent for WebFinger (#7531) 2018-05-18 01:47:22 +02:00
locales Improve payload format of Web Push API now that it's open (#7521) 2018-05-19 14:46:47 +02:00
webpack Limit environment variables to expose to webpack (#7480) 2018-05-14 17:45:37 +02:00
application.rb Add Slovene language (#7475) 2018-05-14 12:52:25 +02:00
boot.rb Upgrade Rails to version 5.2.0 (#5898) 2018-04-12 14:45:17 +02:00
brakeman.ignore Save video metadata and improve video OpenGraph tags (#6481) 2018-02-16 07:22:20 +01:00
database.yml
deploy.rb Update dependencies for Ruby (2018-04-23) (#7237) 2018-04-23 11:29:17 +02:00
environment.rb
i18n-tasks.yml Revert #6479, hide sensitive text/images from OpenGraph previews (#6818) 2018-03-18 20:33:07 +01:00
navigation.rb Add headings to the security settings page (#6661) 2018-03-07 01:39:40 +01:00
puma.rb
routes.rb Add GET /api/v1/push/subscription REST API (#7471) 2018-05-13 21:07:31 +02:00
secrets.yml
settings.yml Add preference to hide following/followers lists (#7532) 2018-05-18 02:26:51 +02:00
sidekiq.yml Account archive download (#6460) 2018-02-21 23:21:32 +01:00
themes.yml Separate high contrast theme (#7213) 2018-04-21 21:35:55 +02:00
webpacker.yml