openapi: 3.0.3 info: title: Silvana Registry Lambda API description: API for Silvana Lambda functions version: 1.0.0 contact: name: API Support servers: - url: https://dhctq4vocgpmdbp5so7jfql26q0ubzms.lambda-url.us-east-1.on.aws description: Lambda Function URL - url: https://wprchl5wjd.execute-api.us-east-1.amazonaws.com/stage description: API Gateway paths: /add: post: summary: Add two numbers operationId: addNumbers description: Calculates the sum of two unsigned 64-bit integers requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/MathRequest' responses: '200': description: Successful calculation content: application/json: schema: $ref: '#/components/schemas/MathResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Internal server error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /multiply: post: summary: Multiply two numbers operationId: multiplyNumbers description: Calculates the product of two unsigned 64-bit integers requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/MathRequest' responses: '200': description: Successful calculation content: application/json: schema: $ref: '#/components/schemas/MathResponse' '400': description: Invalid input or overflow content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Internal server error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /generate-sui-keypair: post: summary: Generate or retrieve a Sui keypair operationId: generateSuiKeypair description: Generates a new Ed25519 keypair for the given login identifier or retrieves existing one requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/SuiKeypairRequest' responses: '200': description: Successfully generated or retrieved keypair content: application/json: schema: $ref: '#/components/schemas/SuiKeypairResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Internal server error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /sign-message: post: summary: Sign a message with a Sui keypair operationId: signMessage description: Signs a message using the Ed25519 keypair for the given login identifier requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/SignMessageRequest' responses: '200': description: Successfully signed message content: application/json: schema: $ref: '#/components/schemas/SignMessageResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '404': description: Keypair not found content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Internal server error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /create-registry: post: summary: Create a Silvana registry on Sui blockchain operationId: createRegistry description: Creates a new Silvana registry with the specified name on the chosen Sui network requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateRegistryRequest' responses: '200': description: Successfully created registry content: application/json: schema: $ref: '#/components/schemas/CreateRegistryResponse' '400': description: Invalid input or insufficient funds content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' '500': description: Internal server error or blockchain error content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /add-developer: post: summary: Add a developer to the registry operationId: addDeveloper requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AddDeveloperRequest' responses: '200': description: Successfully added developer content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /update-developer: post: summary: Update a developer in the registry operationId: updateDeveloper requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateDeveloperRequest' responses: '200': description: Successfully updated developer content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /remove-developer: post: summary: Remove a developer from the registry operationId: removeDeveloper requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/RemoveDeveloperRequest' responses: '200': description: Successfully removed developer content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /add-agent: post: summary: Add an agent to the registry operationId: addAgent requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AddAgentRequest' responses: '200': description: Successfully added agent content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /update-agent: post: summary: Update an agent in the registry operationId: updateAgent requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateAgentRequest' responses: '200': description: Successfully updated agent content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /remove-agent: post: summary: Remove an agent from the registry operationId: removeAgent requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/RemoveAgentRequest' responses: '200': description: Successfully removed agent content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /add-app: post: summary: Add an app to the registry operationId: addApp requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AddAppRequest' responses: '200': description: Successfully added app content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /update-app: post: summary: Update an app in the registry operationId: updateApp requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateAppRequest' responses: '200': description: Successfully updated app content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' /remove-app: post: summary: Remove an app from the registry operationId: removeApp requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/RemoveAppRequest' responses: '200': description: Successfully removed app content: application/json: schema: $ref: '#/components/schemas/TransactionResponse' '400': description: Invalid input content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' components: schemas: MathRequest: type: object required: - a - b properties: a: type: integer format: int64 minimum: 0 maximum: 18446744073709551615 description: First unsigned 64-bit integer example: 100 b: type: integer format: int64 minimum: 0 maximum: 18446744073709551615 description: Second unsigned 64-bit integer example: 200 MathResponse: type: object required: - result - operation properties: result: type: integer format: int64 minimum: 0 maximum: 18446744073709551615 description: Result of the mathematical operation example: 300 operation: type: string enum: [add, multiply] description: The operation that was performed example: add tx_hash: type: string description: Transaction hash from blockchain (only for add operation when using blockchain) example: "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef" Chain: type: string enum: [devnet, testnet, mainnet] description: Sui network example: "devnet" ErrorResponse: type: object required: - error - message properties: error: type: string description: Error code example: INVALID_INPUT message: type: string description: Human-readable error message example: Invalid input parameters SuiKeypairRequest: type: object required: - login_type - login properties: login_type: type: string description: Type of login (e.g., google, github, email) example: "email" login: type: string description: Login identifier (e.g., email address, username) example: "user@example.com" SuiKeypairResponse: type: object required: - address properties: address: type: string description: Sui address derived from the public key example: "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef" SignMessageRequest: type: object required: - login_type - login - message properties: login_type: type: string description: Type of login (e.g., google, github, email) example: "email" login: type: string description: Login identifier (e.g., email address, username) example: "user@example.com" message: type: array items: type: integer minimum: 0 maximum: 255 description: Message to sign as a vector of bytes (u8) example: [72, 101, 108, 108, 111] SignMessageResponse: type: object required: - signature - address properties: signature: type: array items: type: integer minimum: 0 maximum: 255 description: Signed message as a vector of bytes (u8) in Sui signature format example: [0, 156, 234, 123, 45, 67, 89, 101, 112, 134, 156, 178, 190, 201, 223, 234] address: type: string description: Sui address of the signer example: "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef" CreateRegistryRequest: type: object required: - name - chain properties: name: type: string description: Name of the registry to create example: "My Silvana Registry" chain: $ref: '#/components/schemas/Chain' CreateRegistryResponse: type: object required: - registry_id - tx_digest - admin_address properties: registry_id: type: string description: Object ID of the created registry example: "0xabcd1234567890abcdef1234567890abcdef1234567890abcdef1234567890ab" tx_digest: type: string description: Transaction digest from the blockchain example: "DXzqFwFqEFhXGZPgNvUnu1wZYXqzKPdJu5YoHauKNYjh" admin_address: type: string description: Admin address (sender) of the registry example: "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef" TransactionResponse: type: object required: - tx_digest properties: tx_digest: type: string description: Transaction digest from the blockchain example: "DXzqFwFqEFhXGZPgNvUnu1wZYXqzKPdJu5YoHauKNYjh" AddDeveloperRequest: type: object required: - registry_id - chain - name - github properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' name: type: string description: Developer name github: type: string description: GitHub username image: type: string description: Profile image URL nullable: true description: type: string description: Developer description nullable: true site: type: string description: Website URL nullable: true UpdateDeveloperRequest: type: object required: - registry_id - chain - name - github properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' name: type: string description: Developer name github: type: string description: GitHub username image: type: string description: Profile image URL nullable: true description: type: string description: Developer description nullable: true site: type: string description: Website URL nullable: true RemoveDeveloperRequest: type: object required: - registry_id - chain - name - agent_names properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' name: type: string description: Developer name agent_names: type: array items: type: string description: List of agent names to remove with the developer AddAgentRequest: type: object required: - registry_id - chain - developer - name - chains properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' developer: type: string description: Developer name name: type: string description: Agent name image: type: string description: Agent image URL nullable: true description: type: string description: Agent description nullable: true site: type: string description: Agent website nullable: true chains: type: array items: type: string description: Supported blockchains UpdateAgentRequest: type: object required: - registry_id - chain - developer - name - chains properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' developer: type: string description: Developer name name: type: string description: Agent name image: type: string description: Agent image URL nullable: true description: type: string description: Agent description nullable: true site: type: string description: Agent website nullable: true chains: type: array items: type: string description: Supported blockchains RemoveAgentRequest: type: object required: - registry_id - chain - developer - name properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' developer: type: string description: Developer name name: type: string description: Agent name AddAppRequest: type: object required: - registry_id - chain - name properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' name: type: string description: App name description: type: string description: App description nullable: true image: type: string description: App image URL nullable: true site: type: string description: App website nullable: true app_cap: type: string description: App capability object ID nullable: true UpdateAppRequest: type: object required: - registry_id - chain - name properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' name: type: string description: App name description: type: string description: App description nullable: true image: type: string description: App image URL nullable: true site: type: string description: App website nullable: true RemoveAppRequest: type: object required: - registry_id - chain - name properties: registry_id: type: string description: Registry object ID chain: $ref: '#/components/schemas/Chain' name: type: string description: App name