curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: curl with websockets

From: Daniel Stenberg via curl-users <curl-users_at_lists.haxx.se>
Date: Fri, 17 Jun 2022 13:23:39 +0200 (CEST)

On Fri, 17 Jun 2022, Stefan Eissing wrote:

> echo "hello little ws" | curl wss://example.com/

Yes, but I was also thinking sending a default message and then go into the
interactive mode. Like this:

  $ curl -d "hello little ws" wss://example.com/
yes
you
silly
^d

With some initial feedback via Twitter my list of ideas now looks like this:

  - Read stdin and send off as messages. Consider newline as end of fragment.
    (default to text? offer option to set binary)
  - Respond to PINGs automatically
  - Issue PINGs at some default interval (option to switch off/change
    interval?)
  - Allow `-d` to specify (initial) data to send (should the format allow for
    multiple separate frames?)
  - Exit after N messages received, where N can be zero.

-- 
  / daniel.haxx.se
  | Commercial curl support up to 24x7 is available!
  | Private help, bug fixes, support, ports, new features
  | https://curl.se/support.html
-- 
Unsubscribe: https://lists.haxx.se/listinfo/curl-users
Etiquette:   https://curl.se/mail/etiquette.html
Received on 2022-06-17