From af596b6ccf14b4d2fc2f5c6ef04870186d99d828 Mon Sep 17 00:00:00 2001
From: Garrett D'Amore <garrett@damore.org>
Date: Wed, 8 Oct 2025 08:36:47 -0700
Subject: docs: Document new HTTP header iteration options.

---
 docs/man/nng_ws.7.adoc | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

(limited to 'docs/man/nng_ws.7.adoc')

diff --git a/docs/man/nng_ws.7.adoc b/docs/man/nng_ws.7.adoc
index f7034987..bdd6989a 100644
--- a/docs/man/nng_ws.7.adoc
+++ b/docs/man/nng_ws.7.adoc
@@ -114,6 +114,30 @@ macro `NNG_OPT_WS_HEADER`, followed by the name of header field.
 
 Such options can be set on dialers and listener, and retrieved from pipes.
 
+((`NNG_OPT_WS_HEADER_NEXT`))::
+
+(bool) Reading this option advances the header iteration so that the values
+supplied by by `NNG_OPT_WS_HEADER_KEY` and `NNG_OPT_WS_HEADER_VALUE` represnt the
+next HTTP header.  This option is `true` if advancing succeeded, `false`
+if there are no more headers. This option is only valid on connected streams or pipes.
+
+((`NNG_OPT_WS_HEADER_RESET`)):
+
+(bool) Reset the HTTP header iteration so the next call to `NNG_OPT_WS_HEADER_NEXT`
+will start at the first HTTP header.
+
+((`NNG_OPT_WS_HEADER_KEY`)):
+
+(string) This option provides the HTTP header key or name for the currently
+selected HTTP header. It is invalid to read this until `NNG_OPT_WS_HEADER_NEXT` has
+been read with a `true` result.
+
+((`NNG_OPT_WS_HEADER_VALUE`)):
+
+(string) This option provides the HTTP header value of the currently selected
+HTTP header. It is invalid to read this until `NNG_OPT_WS_HEADER_NEXT` has
+been read with a `true` result.
+
 ((`NNG_OPT_WS_RECV_TEXT`))::
 
 (bool) Enable receiving of TEXT frames at the WebSocket layer.
-- 
cgit v1.2.3-70-g09d2

