summaryrefslogtreecommitdiffstats
path: root/contrib/bruno/users
diff options
context:
space:
mode:
authorrtkay123 <dev@kanjala.com>2025-07-19 21:59:54 +0200
committerrtkay123 <dev@kanjala.com>2025-07-19 21:59:54 +0200
commit4616c62bcd899a76062c611b96b13833f782f51e (patch)
tree08623395d1ddabf00b2b42770541df41656b3448 /contrib/bruno/users
parent5758ef50c8b1297e29f32aea105e8821e625ab6f (diff)
downloadsellershut-4616c62bcd899a76062c611b96b13833f782f51e.tar.bz2
sellershut-4616c62bcd899a76062c611b96b13833f782f51e.zip
feat: sign request
Diffstat (limited to 'contrib/bruno/users')
-rw-r--r--contrib/bruno/users/follow.bru29
1 files changed, 29 insertions, 0 deletions
diff --git a/contrib/bruno/users/follow.bru b/contrib/bruno/users/follow.bru
new file mode 100644
index 0000000..89cf4e1
--- /dev/null
+++ b/contrib/bruno/users/follow.bru
@@ -0,0 +1,29 @@
+meta {
+ name: follow
+ type: http
+ seq: 3
+}
+
+post {
+ url: {{HUT_HOSTNAME}}/users/sellershut/inbox
+ body: none
+ auth: inherit
+}
+
+headers {
+ Content-Type: application/activity+json
+}
+
+script:pre-request {
+ const { nanoid } = require("nanoid")
+
+ const hostname = bru.getEnvVar("HUT_HOSTNAME");
+
+ req.setBody({
+ "@context": "https://www.w3.org/ns/activitystreams",
+ "id": `${hostname}/activity/follow/${nanoid()}`,
+ "type": "Follow",
+ "actor": `http://localhost/users/sellershut`,
+ "object": `http://localhost/users/sellershut`
+ })
+}