You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We need to implement the /get_whitelisted_contracts_entrypoints endpoint in the Vault backend. This endpoint is responsible for retrieving the whitelisted entry points of contracts associated with a specific account on StarkNet.
Details
Method: GET
Path: /get_whitelisted_contracts_entrypoints
Summary: Get whitelisted entrypoints of contracts.
Request Parameters:
address: The StarkNet address for which the whitelisted entrypoints of contracts are to be retrieved.
Response:
Status Code: 200
Description: Successful retrieval of whitelisted entrypoints of contracts
The whitelisted entrypoints of contracts are represented as an array of arrays of hexadecimal strings.
Example
// Import necessary modulesimportfastifyfrom'fastify';// Create Fastify instanceconstapp=fastify({logger: true});// Define the get_whitelisted_contracts_entrypoints endpointapp.get('/get_whitelisted_contracts_entrypoints',async(request,reply)=>{try{// Logic to retrieve the whitelisted entrypoints of contracts goes here// Return the whitelisted entrypoints of contractsreturn[["0x0123456789abcdefABCDEF0123456789abcdefABCDEF0123456789abcdefABCD","0x1234567890abcdefABCDEF0123456789abcdefABCDEF0123456789abcdefABC"],["0xABCDEF0123456789abcdef0123456789abcdefABCDEF0123456789abcdef0123","0x0123456789abcdefABCDEF0123456789abcdefABCDEF0123456789abcdefABC"],
...
];}catch(error){// Handle errorsconsole.error('Error while retrieving whitelisted entrypoints of contracts:',error);returnreply.status(500).send({error: 'Internal Server Error'});}});
Tasks:
Implement the /get_whitelisted_contracts_entrypoints endpoint.
The text was updated successfully, but these errors were encountered:
Description
We need to implement the
/get_whitelisted_contracts_entrypoints
endpoint in the Vault backend. This endpoint is responsible for retrieving the whitelisted entry points of contracts associated with a specific account on StarkNet.Details
Request Parameters:
Response:
Notes:
The whitelisted entrypoints of contracts are represented as an array of arrays of hexadecimal strings.
Example
Tasks:
/get_whitelisted_contracts_entrypoints
endpoint.The text was updated successfully, but these errors were encountered: