diff --git a/CHANGELOG.md b/CHANGELOG.md index 6ecde37..6ad0e62 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,8 +4,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog], and this project adheres to [Semantic Versioning]. ## [Unreleased] + +## [1.0.4] - 2024-01-11 ### Changed -- Update GitHub Action Secret EVN_TESTNET with the received public key +- Rename `/verify` to `/rarimo-verify` action ## [1.0.3] - 2024-01-10 ### Added @@ -42,7 +44,8 @@ The format is based on [Keep a Changelog], and this project adheres to [Semantic - Initiated project -[Unreleased]: https://github.com/rarimo/collabland-rarimo-poh-action/compare/1.0.3...HEAD +[Unreleased]: https://github.com/rarimo/collabland-rarimo-poh-action/compare/1.0.4...HEAD +[1.0.4]: https://github.com/rarimo/collabland-rarimo-poh-action/compare/1.0.3...1.0.4 [1.0.3]: https://github.com/rarimo/collabland-rarimo-poh-action/compare/1.0.2...1.0.3 [1.0.2]: https://github.com/rarimo/collabland-rarimo-poh-action/compare/1.0.1...1.0.2 [1.0.1]: https://github.com/rarimo/collabland-rarimo-poh-action/compare/1.0.0...1.0.1 diff --git a/README.md b/README.md index 8213933..4c0243b 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@

Rarimo Proof of Humanity Collab.Land Action

-This repo implements an [Collab.Land] action that adds `/verify` command to your Discord server and +This repo implements an [Collab.Land] action that adds `/rarimo-verify` command to your Discord server and allow members to verify their humanity using the [Rarimo Proof of Humanity] case. ## Table of Contents @@ -133,16 +133,16 @@ services: ## Installing the Collab.Land actions - Follow these steps to install the Collab.Land actions: [Test the Actions in a Discord server] -- Verify your humanity with the `/verify` command +- Verify your humanity with the `/rarimo-verify` command ## API Specifications - The API exposes two routes per slash command: - - GET `/verify/metadata`: To provide the metadata for the `/verify` command - - POST `/verify/interactions`: To handle the Discord interactions corresponding to the `/verify` + - GET `/verify/metadata`: To provide the metadata for the `/rarimo-verify` command + - POST `/verify/interactions`: To handle the Discord interactions corresponding to the `/rarimo-verify` command - The slash commands provide example codes for the following Discord interactions: - - `/verify`: Verify your humanity with Rarimo Proof of Humanity use case and get the verified role + - `/rarimo-verify`: Verify your humanity with Rarimo Proof of Humanity use case and get the verified role in your Discord server. ## Contributing diff --git a/package.json b/package.json index cd4cd35..2e0844a 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "collabland-rarimo-poh-action", - "description": "Implementation of the Collab.Land action /verify command for the Discord server which allows members to verify their humanity using the Rarimo Proof of Humanity case.", - "version": "1.0.3", + "description": "Implementation of the Collab.Land action /rarimo-verify command for the Discord server which allows members to verify their humanity using the Rarimo Proof of Humanity case.", + "version": "1.0.4", "private": true, "license": "MIT", "author": "Zero Block Global Foundation", diff --git a/public/thumbnail-discord-verify-msg.png b/public/thumbnail-discord-verify-msg.png index bac4f2d..c75e15d 100644 Binary files a/public/thumbnail-discord-verify-msg.png and b/public/thumbnail-discord-verify-msg.png differ diff --git a/src/app/api/verify/interactions/route.ts b/src/app/api/verify/interactions/route.ts index 12daac1..8917d52 100644 --- a/src/app/api/verify/interactions/route.ts +++ b/src/app/api/verify/interactions/route.ts @@ -1,4 +1,5 @@ import { handleVerifyAction } from '@/actions' +import { VERIFY_ACTION_NAME } from '@/const' import { verifyCollablandRequest } from '@/helpers' import { badRequestAction, unathorizedAction } from '@/http' @@ -8,7 +9,7 @@ export const POST = async (request: Request) => { if (!verifyResult.verified) return unathorizedAction(verifyResult.reason) - if (interaction?.data?.name === 'verify') { + if (interaction?.data?.name === VERIFY_ACTION_NAME) { return handleVerifyAction(interaction) } diff --git a/src/const/metadata.ts b/src/const/metadata.ts index 8df37dc..fc32979 100644 --- a/src/const/metadata.ts +++ b/src/const/metadata.ts @@ -10,6 +10,8 @@ const craftPublicImgUrl = (imgName: string): string => { return new URL(`/${imgName}`, config.appUrl).toString() } +export const VERIFY_ACTION_NAME = 'rarimo-verify' + const manifest = new MiniAppManifest({ appId: PackageJson.name, name: 'Proof of Humanity', @@ -60,7 +62,7 @@ export const METADATA: DiscordActionMetadata = { { // Handle verify slash command type: InteractionType.ApplicationCommand, - names: ['verify'], + names: [VERIFY_ACTION_NAME], }, ], /** @@ -71,10 +73,10 @@ export const METADATA: DiscordActionMetadata = { { metadata: { name: 'Verify your humanity with Rarimo', - shortName: 'verify', + shortName: VERIFY_ACTION_NAME, supportedEnvs: ['production', 'development'], }, - name: 'verify', + name: VERIFY_ACTION_NAME, type: ApplicationCommandType.ChatInput, description: 'Redirects you to Proof of Humanity DApp for verification', options: [],