summaryrefslogtreecommitdiffstats
path: root/contrib/bruno/users/follow.bru
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/bruno/users/follow.bru')
-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`
+ })
+}