Skip to content

Commit

Permalink
added create identity route
Browse files Browse the repository at this point in the history
  • Loading branch information
agustinkassis committed Sep 28, 2023
1 parent 4cd2675 commit c3c7542
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions pages/identity-provider/api/identity/create.mdx
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
# Create Identity

Creates an Identity.
**Required**: Authorized pubkey must sign the request.
**Required**: Unburned nonce

---

## Request

> **POST** /api/identity/create
> **POST** /api/identity
### Parameters

username
name
: `String`
The username of the account to create

Expand All @@ -31,16 +31,17 @@ The **body** should be wrapped in a NOSTR event, included in the `content`
{
"id": "eventHash",
"pubkey": "AUTHORIZED_PUB_KEY",
"created_at": 1673347337,
"kind": 1, // TODO: define kind
"kind": 1112,
"content": {
"username": "string",
"name": "string",
"pubkey": "string",
"lud16": {
...
}
},
"tags": [],
"tags": [
["nonce", "BURNABLE_NONCE"],
],
"sig": "signature of AUTHORIZED_PUB_KEY"
}
```
Expand Down Expand Up @@ -100,7 +101,7 @@ Conflict
```json
{
"success": false,
"reason": "Username already taken"
"reason": "Name already taken"
}
```

Expand Down

0 comments on commit c3c7542

Please sign in to comment.