This guide provides comprehensive information for frontend engineers to integrate with the Cap Protocol v4 smart contracts deployed on Arbitrum Sepolia.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
// author: yoyoismee.eth | |
pragma solidity 0.8.14; | |
import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; | |
import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; | |
// @notice - free mint that allow contract to mint might not be the best idea ? | |
// @dev maybe you should add something like requrie(msg.sender == tx.origin) ? | |
// yeah not sure if this intended. but you know that 5 is not the limit right? I cound just mint up to the gas limit. | |
// I'll reach out to the creator to see if she want it back. but yeah maybe be more careful next time quixotic team. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
users = await UserMobile.aggregate([ | |
{ | |
$match: query, | |
}, | |
{ | |
$lookup: { from: 'userpackages', localField: 'userPackage', foreignField: '_id', as: 'userPackage' }, | |
}, | |
{ | |
$lookup: { from: 'dates', localField: '_id', foreignField: 'owner', as: 'activeDate' }, | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe("OneClickMint", () => { | |
let contract; | |
beforeEach(async () => { | |
contract = await deployContract(); | |
}); | |
describe("# Minting with TCR 0.5", () => { | |
beforeEach(async () => { | |
await contract.setTCR("0.5"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#------------------------------------------------------------------------------ | |
# solidity.rb | |
# | |
# Homebrew formula for solidity. Homebrew (http://brew.sh/) is | |
# the de-facto standard package manager for OS X, and this Ruby script | |
# contains the metadata used to map command-line user settings used | |
# with the 'brew' command onto build options. | |
# | |
# Our documentation for the solidity Homebrew setup is at: | |
# |
I hereby claim:
- I am nanmcpe on github.
- I am thanwa (https://keybase.io/thanwa) on keybase.
- I have a public key whose fingerprint is B362 4538 AC34 4D9D A4B0 61A0 E39E CB8A FA78 040B
To claim this, I am signing this object:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.3' | |
services: | |
ganache-cli: | |
container_name: ganache-cli | |
image: trufflesuite/ganache-cli:latest | |
ports: | |
- 8545:8545 | |
restart: always | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "2" | |
services: | |
sonarqube: | |
image: sonarqube | |
expose: | |
- 9000 | |
ports: | |
- "127.0.0.1:9000:9000" | |
networks: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GRPC | REST | |
---|---|---|
Protocol Buffers - smaller and faster | JSON - text ased - slower and bigger | |
HTTP/2 (lower latency) - from 2015 | HTTP/1.1 (higher latency) from 1997 | |
Bidirectional & Async | Client => Server requests only | |
Stream Support | Request/ Response support only | |
API Oriented - What (no constraints - free design) | CRUD Oriented (Create - Retrive - Update - Delete / GET POST PUT DELETE) | |
Code Generation through Protocol Buffers in any language 1st class citizen | Code feneratiion through OpenAPI / Swagger (add-on) - 2nd class citizen | |
RPC Based - gRPC does the plumbing for us | HTTP verbs based - we have to write the plumbing or use a 3rd party library |
I hereby claim:
- I am nanthan on github.
- I am thanwa (https://keybase.io/thanwa) on keybase.
- I have a public key ASDoD4Gzws5CklvWp_XI2fcCbpphX1PBna7U2Lt1zp0moQo
To claim this, I am signing this object:
NewerOlder