Skip to content

No clear way to publish an action in ws-message format #7

@kwellman

Description

@kwellman

The documentation (https://pushpin.org/docs/usage/#subscribing) gives this example to publish a close action:

POST /publish HTTP/1.1
Host: localhost:5561
Content-Type: application/json

{
  "items": [
    {
      "channel": "mychannel",
      "id": "an-item-id",
      "formats": {
        "ws-message": {
          "action": "close",
          "code": 1013,
          "reason": "bye for now",
        }
      }
    }
  ]
}

I can't figure out a way to do this using this library besides writing my own custom message format class since the WebSocketMessageFormat class only has content parameter.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions