├── .eslintignore ├── .eslintrc.js ├── .gitattributes ├── .github └── workflows │ └── ci.yml ├── .gitignore ├── .prettierrc.js ├── README.md ├── examples └── defender-test-project │ ├── .gitignore │ ├── abis │ ├── demoflash.json.abi │ └── erc721.json.abi │ ├── autotasks │ └── hello-world │ │ └── index.js │ ├── package.json │ ├── serverless.yml │ └── yarn.lock ├── package.json ├── src ├── cmd │ ├── deploy.ts │ ├── info.ts │ ├── invoke.ts │ ├── logs.ts │ └── remove.ts ├── index.ts ├── provider.ts ├── types │ ├── docs-schemas │ │ ├── defender.schema.json │ │ ├── definitions.schema.json │ │ ├── function.schema.json │ │ ├── provider.schema.json │ │ └── resources.schema.json │ ├── docs │ │ ├── README.md │ │ ├── defender-properties-key.md │ │ ├── defender-properties-secret.md │ │ ├── defender.md │ │ ├── definitions-definitions-abitype-anyof-arrayabi.md │ │ ├── definitions-definitions-abitype-anyof-stringabi.md │ │ ├── definitions-definitions-abitype.md │ │ ├── definitions-definitions-address.md │ │ ├── definitions-definitions-autotask-properties-name.md │ │ ├── definitions-definitions-autotask-properties-path.md │ │ ├── definitions-definitions-autotask-properties-paused.md │ │ ├── definitions-definitions-autotask-properties-trigger-else.md │ │ ├── definitions-definitions-autotask-properties-trigger-if-properties-type.md │ │ ├── definitions-definitions-autotask-properties-trigger-if-properties.md │ │ ├── definitions-definitions-autotask-properties-trigger-if.md │ │ ├── definitions-definitions-autotask-properties-trigger-properties-triggercron.md │ │ ├── definitions-definitions-autotask-properties-trigger-properties-triggerfrequency.md │ │ ├── definitions-definitions-autotask-properties-trigger-properties-triggertype.md │ │ ├── definitions-definitions-autotask-properties-trigger-then-oneof-0.md │ │ ├── definitions-definitions-autotask-properties-trigger-then-oneof-1.md │ │ ├── definitions-definitions-autotask-properties-trigger-then.md │ │ ├── definitions-definitions-autotask-properties-trigger.md │ │ ├── definitions-definitions-autotask.md │ │ ├── definitions-definitions-blockexplorerapikey-properties-key.md │ │ ├── definitions-definitions-blockexplorerapikey.md │ │ ├── definitions-definitions-blocksentinel-properties-addresses.md │ │ ├── definitions-definitions-blocksentinel-properties-alertthreshold-properties-amount.md │ │ ├── definitions-definitions-blocksentinel-properties-alertthreshold-properties-window-seconds.md │ │ ├── definitions-definitions-blocksentinel-properties-alertthreshold.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-expression.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-signature.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-event.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-expression.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-signature.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-function.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions-properties-transaction.md │ │ ├── definitions-definitions-blocksentinel-properties-conditions.md │ │ ├── definitions-definitions-blocksentinel-properties-confirm-level-oneof-0.md │ │ ├── definitions-definitions-blocksentinel-properties-confirm-level-oneof-1.md │ │ ├── definitions-definitions-blocksentinel-properties-confirm-level.md │ │ ├── definitions-definitions-blocksentinel-properties-name.md │ │ ├── definitions-definitions-blocksentinel-properties-notifyconfig-properties-channels.md │ │ ├── definitions-definitions-blocksentinel-properties-notifyconfig-properties-message.md │ │ ├── definitions-definitions-blocksentinel-properties-notifyconfig-properties-timeout.md │ │ ├── definitions-definitions-blocksentinel-properties-notifyconfig.md │ │ ├── definitions-definitions-blocksentinel-properties-paused.md │ │ ├── definitions-definitions-blocksentinel-properties-type.md │ │ ├── definitions-definitions-blocksentinel.md │ │ ├── definitions-definitions-category-properties-description.md │ │ ├── definitions-definitions-category-properties-name.md │ │ ├── definitions-definitions-category-properties-notificationids.md │ │ ├── definitions-definitions-category.md │ │ ├── definitions-definitions-contract-properties-name.md │ │ ├── definitions-definitions-contract-properties-nat-spec.md │ │ ├── definitions-definitions-contract.md │ │ ├── definitions-definitions-datadogconfig-properties-api-key.md │ │ ├── definitions-definitions-datadogconfig-properties-metric-prefix.md │ │ ├── definitions-definitions-datadogconfig.md │ │ ├── definitions-definitions-deploymentconfig.md │ │ ├── definitions-definitions-emailconfig-properties-emails-items.md │ │ ├── definitions-definitions-emailconfig-properties-emails.md │ │ ├── definitions-definitions-emailconfig.md │ │ ├── definitions-definitions-fortasentinel-anyof-0.md │ │ ├── definitions-definitions-fortasentinel-anyof-1.md │ │ ├── definitions-definitions-fortasentinel-properties-addresses.md │ │ ├── definitions-definitions-fortasentinel-properties-agentids-items.md │ │ ├── definitions-definitions-fortasentinel-properties-agentids.md │ │ ├── definitions-definitions-fortasentinel-properties-alertthreshold-properties-amount.md │ │ ├── definitions-definitions-fortasentinel-properties-alertthreshold-properties-window-seconds.md │ │ ├── definitions-definitions-fortasentinel-properties-alertthreshold.md │ │ ├── definitions-definitions-fortasentinel-properties-conditions-properties-alertids-items.md │ │ ├── definitions-definitions-fortasentinel-properties-conditions-properties-alertids.md │ │ ├── definitions-definitions-fortasentinel-properties-conditions-properties-min-scanner-count.md │ │ ├── definitions-definitions-fortasentinel-properties-conditions-properties-severity.md │ │ ├── definitions-definitions-fortasentinel-properties-conditions.md │ │ ├── definitions-definitions-fortasentinel-properties-forta-node-id.md │ │ ├── definitions-definitions-fortasentinel-properties-name.md │ │ ├── definitions-definitions-fortasentinel-properties-notifyconfig-properties-channels.md │ │ ├── definitions-definitions-fortasentinel-properties-notifyconfig-properties-message.md │ │ ├── definitions-definitions-fortasentinel-properties-notifyconfig-properties-timeout.md │ │ ├── definitions-definitions-fortasentinel-properties-notifyconfig.md │ │ ├── definitions-definitions-fortasentinel-properties-paused.md │ │ ├── definitions-definitions-fortasentinel-properties-type.md │ │ ├── definitions-definitions-fortasentinel.md │ │ ├── definitions-definitions-network.md │ │ ├── definitions-definitions-notification-properties-config.md │ │ ├── definitions-definitions-notification-properties-name.md │ │ ├── definitions-definitions-notification-properties-paused.md │ │ ├── definitions-definitions-notification.md │ │ ├── definitions-definitions-notificationtype.md │ │ ├── definitions-definitions-opsgenieconfig-properties-actions-items.md │ │ ├── definitions-definitions-opsgenieconfig-properties-actions.md │ │ ├── definitions-definitions-opsgenieconfig-properties-alias.md │ │ ├── definitions-definitions-opsgenieconfig-properties-apikey.md │ │ ├── definitions-definitions-opsgenieconfig-properties-details-additionalproperties.md │ │ ├── definitions-definitions-opsgenieconfig-properties-details.md │ │ ├── definitions-definitions-opsgenieconfig-properties-entity.md │ │ ├── definitions-definitions-opsgenieconfig-properties-note.md │ │ ├── definitions-definitions-opsgenieconfig-properties-responders.md │ │ ├── definitions-definitions-opsgenieconfig-properties-tags-items.md │ │ ├── definitions-definitions-opsgenieconfig-properties-tags.md │ │ ├── definitions-definitions-opsgenieconfig-properties-visibleto.md │ │ ├── definitions-definitions-opsgenieconfig-properties.md │ │ ├── definitions-definitions-opsgenieconfig.md │ │ ├── definitions-definitions-opsgenieinstancelocation.md │ │ ├── definitions-definitions-opsgenieprioritylevel.md │ │ ├── definitions-definitions-opsgenieuser-properties-fullname.md │ │ ├── definitions-definitions-opsgenieuser-properties-id.md │ │ ├── definitions-definitions-opsgenieuser-properties-username.md │ │ ├── definitions-definitions-opsgenieuser.md │ │ ├── definitions-definitions-opsgenieusertype.md │ │ ├── definitions-definitions-pagerdutyconfig-if-properties-eventtype.md │ │ ├── definitions-definitions-pagerdutyconfig-if-properties.md │ │ ├── definitions-definitions-pagerdutyconfig-if.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-class.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-component.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-customdetails-additionalproperties.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-customdetails.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-dedupkey.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-group.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-routingkey.md │ │ ├── definitions-definitions-pagerdutyconfig-properties-token.md │ │ ├── definitions-definitions-pagerdutyconfig-properties.md │ │ ├── definitions-definitions-pagerdutyconfig-then.md │ │ ├── definitions-definitions-pagerdutyconfig.md │ │ ├── definitions-definitions-pagerdutyeventaction.md │ │ ├── definitions-definitions-pagerdutyeventtype.md │ │ ├── definitions-definitions-pagerdutyseverity.md │ │ ├── definitions-definitions-policy-properties-eip1559-pricing.md │ │ ├── definitions-definitions-policy-properties-gas-price-cap.md │ │ ├── definitions-definitions-policy-properties-private-transactions.md │ │ ├── definitions-definitions-policy-properties-whitelistreceivers-items.md │ │ ├── definitions-definitions-policy-properties-whitelistreceivers.md │ │ ├── definitions-definitions-policy.md │ │ ├── definitions-definitions-relayer-properties-addressfromrelayer.md │ │ ├── definitions-definitions-relayer-properties-min-balance.md │ │ ├── definitions-definitions-relayer-properties-name.md │ │ ├── definitions-definitions-relayer-properties-relayerapikeys-items.md │ │ ├── definitions-definitions-relayer-properties-relayerapikeys.md │ │ ├── definitions-definitions-relayer.md │ │ ├── definitions-definitions-riskcategory.md │ │ ├── definitions-definitions-sentinel.md │ │ ├── definitions-definitions-telegramconfig-properties-bot-token.md │ │ ├── definitions-definitions-telegramconfig-properties-chat-id.md │ │ ├── definitions-definitions-telegramconfig.md │ │ ├── definitions-definitions-urlconfig-properties-url.md │ │ ├── definitions-definitions-urlconfig.md │ │ ├── definitions-definitions.md │ │ ├── definitions.md │ │ ├── function-properties-path.md │ │ ├── function-properties-paused.md │ │ ├── function-properties-trigger-else.md │ │ ├── function-properties-trigger-if-properties-type.md │ │ ├── function-properties-trigger-if-properties.md │ │ ├── function-properties-trigger-if.md │ │ ├── function-properties-trigger-properties-triggercron.md │ │ ├── function-properties-trigger-properties-triggerfrequency.md │ │ ├── function-properties-trigger-properties-triggertype.md │ │ ├── function-properties-trigger-then-oneof-0.md │ │ ├── function-properties-trigger-then-oneof-1.md │ │ ├── function-properties-trigger-then.md │ │ ├── function-properties-trigger.md │ │ ├── function.md │ │ ├── provider-properties-ssot.md │ │ ├── provider-properties-stackname.md │ │ ├── provider-properties-stage.md │ │ ├── provider.md │ │ ├── resources-properties-resources-properties-autotasksecrets-properties-global-additionalproperties.md │ │ ├── resources-properties-resources-properties-autotasksecrets-properties-global.md │ │ ├── resources-properties-resources-properties-autotasksecrets-properties-stack-additionalproperties.md │ │ ├── resources-properties-resources-properties-autotasksecrets-properties-stack.md │ │ ├── resources-properties-resources-properties-autotasksecrets.md │ │ ├── resources-properties-resources-properties-block-explorer-api-keys.md │ │ ├── resources-properties-resources-properties-contracts.md │ │ ├── resources-properties-resources-properties-deployment-configs.md │ │ ├── resources-properties-resources-properties-notifications.md │ │ ├── resources-properties-resources-properties-policies.md │ │ ├── resources-properties-resources-properties-relayers.md │ │ ├── resources-properties-resources-properties-sentinels.md │ │ ├── resources-properties-resources.md │ │ └── resources.md │ ├── index.ts │ └── schemas │ │ ├── configs │ │ ├── replace-ref-config.ts │ │ └── replace-undefined-config.ts │ │ ├── defender.schema.json │ │ ├── definitions.schema.json │ │ ├── function.schema.json │ │ ├── index.ts │ │ ├── provider.schema.json │ │ └── resources.schema.json └── utils │ ├── index.ts │ ├── logger.ts │ └── sanitise.ts ├── template ├── .gitignore ├── README.md ├── autotasks │ └── hello-world │ │ └── index.js ├── package.json ├── serverless.yml └── yarn.lock ├── tsconfig.json └── yarn.lock /.eslintignore: -------------------------------------------------------------------------------- 1 | /lib 2 | /test 3 | /node_modules -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | parser: '@typescript-eslint/parser', // Specifies the ESLint parser 3 | extends: [ 4 | 'plugin:@typescript-eslint/recommended', // Uses the recommended rules from the @typescript-eslint/eslint-plugin 5 | 'plugin:prettier/recommended', // Enables eslint-plugin-prettier and eslint-config-prettier. This will display prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array. 6 | ], 7 | parserOptions: { 8 | ecmaVersion: 2018, // Allows for the parsing of modern ECMAScript features 9 | sourceType: 'module', // Allows for the use of imports 10 | }, 11 | rules: {}, 12 | }; 13 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Apply override to all files and directories in the directory 2 | src/types/docs/** linguist-generated 3 | src/types/schemas/** linguist-generated -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- 1 | name: CI 2 | 3 | on: [push] 4 | 5 | jobs: 6 | build: 7 | 8 | runs-on: ubuntu-latest 9 | 10 | steps: 11 | - uses: actions/checkout@v2 12 | 13 | - name: Use node@14 14 | uses: actions/setup-node@v1 15 | with: { node-version: '14.x' } 16 | 17 | - name: Node modules cache 18 | uses: actions/cache@v2 19 | id: yarn-cache 20 | with: 21 | path: | 22 | ${{ steps.yarn-cache-dir-path.outputs.dir }} 23 | ~/.cache/node-gyp-cache 24 | key: "${{ runner.os }}-yarn-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }}" 25 | restore-keys: | 26 | ${{ runner.os }}-yarn-${{ env.cache-name }}- 27 | env: 28 | cache-name: v4 29 | 30 | - name: Install dependencies 31 | run: yarn --frozen-lockfile 32 | 33 | - name: Check build 34 | run: yarn build 35 | 36 | - name: Check linting 37 | run: yarn lint:check 38 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # package directories 2 | node_modules 3 | lib 4 | 5 | # Other 6 | .env 7 | *.log 8 | .DS_Store 9 | tsconfig.tsbuildinfo 10 | 11 | .vscode 12 | 13 | # example deployments 14 | examples/defender-test-project/.defender 15 | examples/defender-test-project/.serverless 16 | -------------------------------------------------------------------------------- /.prettierrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | ...require('code-style/.prettierrc.js'), 3 | }; 4 | -------------------------------------------------------------------------------- /examples/defender-test-project/.gitignore: -------------------------------------------------------------------------------- 1 | # package directories 2 | node_modules 3 | jspm_packages 4 | 5 | # Serverless directories 6 | .serverless 7 | 8 | # Other 9 | .env 10 | *.log 11 | .DS_Store 12 | 13 | # Defender 14 | secrets*.yml 15 | .defender -------------------------------------------------------------------------------- /examples/defender-test-project/abis/demoflash.json.abi: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "anonymous": false, 4 | "inputs": [ 5 | { 6 | "indexed": false, 7 | "internalType": "address", 8 | "name": "addr", 9 | "type": "address" 10 | }, 11 | { 12 | "indexed": false, 13 | "internalType": "string", 14 | "name": "m", 15 | "type": "string" 16 | } 17 | ], 18 | "name": "Addr", 19 | "type": "event" 20 | }, 21 | { 22 | "anonymous": false, 23 | "inputs": [ 24 | { 25 | "indexed": false, 26 | "internalType": "uint256", 27 | "name": "_0", 28 | "type": "uint256" 29 | }, 30 | { 31 | "indexed": false, 32 | "internalType": "uint256", 33 | "name": "_1", 34 | "type": "uint256" 35 | }, 36 | { 37 | "indexed": false, 38 | "internalType": "string", 39 | "name": "m", 40 | "type": "string" 41 | } 42 | ], 43 | "name": "Amt", 44 | "type": "event" 45 | }, 46 | { 47 | "anonymous": false, 48 | "inputs": [ 49 | { 50 | "indexed": false, 51 | "internalType": "uint256", 52 | "name": "_0", 53 | "type": "uint256" 54 | }, 55 | { 56 | "indexed": false, 57 | "internalType": "string", 58 | "name": "m", 59 | "type": "string" 60 | } 61 | ], 62 | "name": "Amt", 63 | "type": "event" 64 | }, 65 | { 66 | "anonymous": false, 67 | "inputs": [ 68 | { 69 | "indexed": false, 70 | "internalType": "address", 71 | "name": "tokenA", 72 | "type": "address" 73 | }, 74 | { 75 | "indexed": false, 76 | "internalType": "address", 77 | "name": "tokenB", 78 | "type": "address" 79 | }, 80 | { 81 | "indexed": false, 82 | "internalType": "uint256", 83 | "name": "output", 84 | "type": "uint256" 85 | } 86 | ], 87 | "name": "Arbitrage", 88 | "type": "event" 89 | }, 90 | { 91 | "anonymous": false, 92 | "inputs": [ 93 | { 94 | "indexed": false, 95 | "internalType": "address", 96 | "name": "tokenA", 97 | "type": "address" 98 | }, 99 | { 100 | "indexed": false, 101 | "internalType": "address", 102 | "name": "tokenB", 103 | "type": "address" 104 | }, 105 | { 106 | "indexed": false, 107 | "internalType": "uint256", 108 | "name": "minimumOutput", 109 | "type": "uint256" 110 | } 111 | ], 112 | "name": "ArbitrageFailed", 113 | "type": "event" 114 | }, 115 | { 116 | "anonymous": false, 117 | "inputs": [ 118 | { 119 | "indexed": false, 120 | "internalType": "int256", 121 | "name": "x1", 122 | "type": "int256" 123 | }, 124 | { 125 | "indexed": false, 126 | "internalType": "int256", 127 | "name": "x2", 128 | "type": "int256" 129 | } 130 | ], 131 | "name": "CalX", 132 | "type": "event" 133 | }, 134 | { 135 | "anonymous": false, 136 | "inputs": [ 137 | { 138 | "indexed": false, 139 | "internalType": "uint256", 140 | "name": "input", 141 | "type": "uint256" 142 | }, 143 | { 144 | "indexed": false, 145 | "internalType": "uint256", 146 | "name": "output", 147 | "type": "uint256" 148 | } 149 | ], 150 | "name": "Sqrt", 151 | "type": "event" 152 | }, 153 | { 154 | "anonymous": false, 155 | "inputs": [ 156 | { 157 | "indexed": false, 158 | "internalType": "address", 159 | "name": "sender", 160 | "type": "address" 161 | }, 162 | { 163 | "indexed": false, 164 | "internalType": "uint256", 165 | "name": "amount0", 166 | "type": "uint256" 167 | }, 168 | { 169 | "indexed": false, 170 | "internalType": "uint256", 171 | "name": "amount1", 172 | "type": "uint256" 173 | }, 174 | { 175 | "indexed": false, 176 | "internalType": "bytes", 177 | "name": "data", 178 | "type": "bytes" 179 | } 180 | ], 181 | "name": "UniswapCalled", 182 | "type": "event" 183 | }, 184 | { 185 | "inputs": [], 186 | "name": "flash", 187 | "outputs": [], 188 | "stateMutability": "payable", 189 | "type": "function" 190 | }, 191 | { 192 | "inputs": [ 193 | { "internalType": "address", "name": "sender", "type": "address" }, 194 | { "internalType": "uint256", "name": "amount0", "type": "uint256" }, 195 | { "internalType": "uint256", "name": "amount1", "type": "uint256" }, 196 | { "internalType": "bytes", "name": "data", "type": "bytes" } 197 | ], 198 | "name": "uniswapV2Call", 199 | "outputs": [], 200 | "stateMutability": "nonpayable", 201 | "type": "function" 202 | } 203 | ] 204 | -------------------------------------------------------------------------------- /examples/defender-test-project/autotasks/hello-world/index.js: -------------------------------------------------------------------------------- 1 | exports.handler = async function (event) { 2 | console.log(`Hello world from serverless`); 3 | console.log(JSON.stringify(event)); 4 | return `Hello world from serverless`; 5 | }; 6 | -------------------------------------------------------------------------------- /examples/defender-test-project/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "defender-test-project", 3 | "version": "1.0.0", 4 | "description": "Test project for the defender-serverless plugin", 5 | "main": "handler.js", 6 | "engines": { 7 | "node": ">14.16" 8 | }, 9 | "scripts": { 10 | "test": "echo \"Error: no test specified\" && exit 1" 11 | }, 12 | "contributors": [ 13 | { 14 | "name": "Santiago Palladino", 15 | "email": "santiago@openzeppelin.com" 16 | }, 17 | { 18 | "name": "Nami Shah", 19 | "email": "nami@openzeppelin.com" 20 | } 21 | ], 22 | "license": "MIT", 23 | "devDependencies": { 24 | "@openzeppelin/defender-serverless": "^1.2.1", 25 | "serverless": "^3.20.0" 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /examples/defender-test-project/serverless.yml: -------------------------------------------------------------------------------- 1 | service: defender-serverless-test-project 2 | configValidationMode: error 3 | frameworkVersion: '3' 4 | 5 | provider: 6 | name: defender 7 | stage: ${opt:stage, 'dev'} 8 | stackName: 'mystack' 9 | # SSOT: use this template as a single source of truth. 10 | # This will delete Defender resources (with the exception of Relayers) not found in this template upon deployment. 11 | ssot: false 12 | 13 | custom: 14 | config: ${file(secrets.${self:provider.stage}.yml)} 15 | 16 | defender: 17 | key: ${self:custom.config.keys.api} 18 | secret: ${self:custom.config.keys.secret} 19 | 20 | functions: 21 | autotask-example-1: 22 | name: 'Hello world from serverless' 23 | path: './autotasks/hello-world' 24 | # optional 25 | relayer: ${self:resources.Resources.relayers.relayer-1} 26 | trigger: 27 | type: 'schedule' # or webhook 28 | # optional if not cron 29 | frequency: 1500 30 | # optional 31 | cron: null 32 | paused: false 33 | autotask-example-2: 34 | name: 'Hello world from serverless 2' 35 | path: './autotasks/hello-world' 36 | trigger: 37 | type: 'schedule' 38 | cron: '0 */12 * * *' 39 | paused: false 40 | autotask-example-3: 41 | name: 'Hello world from serverless 3' 42 | path: './autotasks/hello-world' 43 | trigger: 44 | type: 'webhook' 45 | paused: false 46 | 47 | resources: 48 | Resources: 49 | policies: 50 | policy-1: 51 | # optional 52 | gas-price-cap: 1000 53 | # optional 54 | whitelist-receivers: 55 | - '0x0f06aB75c7DD497981b75CD82F6566e3a5CAd8f2' 56 | # optional 57 | eip1559-pricing: true 58 | private-transactions: true 59 | 60 | secrets: 61 | # optional - global secrets are not affected by stackName changes 62 | global: 63 | foo: ${self:custom.config.secrets.foo} 64 | hello: ${self:custom.config.secrets.hello} 65 | test: ${self:custom.config.secrets.test} 66 | # optional - stack secrets (formatted as _) 67 | stack: 68 | test: ${self:custom.config.secrets.test} 69 | 70 | contracts: 71 | contract-1: 72 | name: 'Demo-Flash' 73 | address: '0xA91382E82fB676d4c935E601305E5253b3829dCD' 74 | network: 'mainnet' 75 | # optional 76 | abi: ${file(./abis/demoflash.json.abi)} 77 | # optional 78 | nat-spec: null 79 | 80 | relayers: 81 | relayer-1: 82 | name: 'Test Relayer 1' 83 | network: 'sepolia' 84 | min-balance: 1000 85 | # optional 86 | policy: ${self:resources.Resources.policies.policy-1} 87 | relayer-2: 88 | name: 'Test Relayer 2' 89 | network: 'mainnet' 90 | min-balance: 1000 91 | # optional (make sure relayer-1 is above current relayer) 92 | address-from-relayer: ${self:resources.Resources.relayers.relayer-1} 93 | # optional 94 | policy: ${self:resources.Resources.policies.policy-1} 95 | 96 | notifications: 97 | email-1: 98 | type: 'email' 99 | name: 'Nami' 100 | config: 101 | emails: 102 | - ${self:custom.config.notifications.nami} 103 | paused: false 104 | slack-1: 105 | type: 'slack' 106 | name: 'Workspace Slack' 107 | config: 108 | url: ${self:custom.config.notifications.slack} 109 | paused: false 110 | 111 | categories: 112 | high-severity: 113 | name: High Severity 114 | # optional 115 | description: A default category to be assigned for high risk monitors. 116 | low-severity: 117 | name: Low Severity 118 | # optional 119 | description: A default category to be assigned for low risk monitors. 120 | medium-severity: 121 | name: Medium Severity 122 | # optional 123 | description: A default category to be assigned for medium risk monitors. 124 | # optional 125 | notification-ids: 126 | - ${self:resources.Resources.notifications.email-1} 127 | - ${self:resources.Resources.notifications.slack-1} 128 | 129 | sentinels: 130 | # unique resource name 131 | block-example: 132 | name: 'Block Example' 133 | type: 'BLOCK' 134 | network: 'sepolia' 135 | risk-category: 'TECHNICAL' # optional 136 | addresses: 137 | - '0x0f06aB75c7DD497981b75CD82F6566e3a5CAd8f2' 138 | # optional 139 | abi: ${file(./abis/erc721.json.abi)} 140 | # optional 141 | alert-threshold: 142 | amount: 2 143 | window-seconds: 3600 144 | # optional 145 | paused: false 146 | # optional 147 | autotask-condition: ${self:functions.autotask-example-1} 148 | # optional 149 | autotask-trigger: null 150 | # optional 151 | confirm-level: 1 # or 'safe' or 'finalized' 152 | notify-config: 153 | timeout: 0 # optional 154 | message: null # optional 155 | channels: 156 | - ${self:resources.Resources.notifications.email-1} 157 | # optional 158 | conditions: 159 | event: 160 | - signature: 'OwnershipTransferred(address,address)' 161 | expression: 'previousOwner=0x0f06aB75c7DD497981b75CD82F6566e3a5CAd8f2' # optional 162 | function: 163 | - signature: 'renounceOwnership()' 164 | expression: null # optional 165 | transaction: 'gasPrice > 0' # optional expression 166 | forta-example: 167 | name: 'Forta Example' 168 | type: 'FORTA' 169 | network: 'mainnet' 170 | # optional if agent-ids is defined 171 | addresses: 172 | - '0x318958A61A3dFa42fBdAA6A28A4F481678D943cC' 173 | # optional 174 | alert-threshold: 175 | amount: 2 176 | window-seconds: 3600 177 | # optional 178 | paused: false 179 | # optional 180 | autotask-condition: ${self:functions.autotask-example-1} 181 | # optional 182 | autotask-trigger: null 183 | notify-config: 184 | timeout: 0 # optional 185 | message: null # optional 186 | channels: [] # assign channels as empty list if you wish to use a category 187 | category: ${self:resources.Resources.categories.medium-severity} # optional (only used if channels is empty) 188 | # optional 189 | conditions: 190 | min-scanner-count: 1 191 | severity: 2 # optional (unknown=0, info=1, low=2, medium=3, high=4, critical=5) 192 | # optional 193 | alert-ids: 194 | - '123' 195 | - '456' 196 | # optional 197 | forta-node-id: '123' 198 | # optional if addresses is defined 199 | agent-ids: 200 | - '0x8fe07f1a4d33b30be2387293f052c273660c829e9a6965cf7e8d485bcb871083' 201 | # optional 202 | forta-last-processed-time: null 203 | 204 | plugins: 205 | - '@openzeppelin/defender-serverless' 206 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@openzeppelin/defender-serverless", 3 | "version": "1.2.3", 4 | "description": "Configure your Defender environment via code", 5 | "main": "./lib/index.js", 6 | "types": "./lib/index.d.ts", 7 | "scripts": { 8 | "build": "rm -rf lib tsconfig.tsbuildinfo && tsc && yarn build:schemas", 9 | "test": "yarn test:unit", 10 | "test:unit": "jest --verbose --passWithNoTests", 11 | "watch": "tsc -w", 12 | "prepare": "yarn build", 13 | "lint": "yarn lint:check --fix", 14 | "lint:check": "eslint 'src/**/*.{js,ts}' --quiet", 15 | "format": "yarn format:check --write", 16 | "format:check": "prettier --check 'src/**/*.(js|ts)'", 17 | "style": "yarn lint && yarn format", 18 | "build:schemas": "yarn generate:schemas && yarn format:schemas", 19 | "generate:schemas": "rm -rf src/types/docs && jsonschema2md -d src/types/docs-schemas -o src/types/docs -x src/types/schemas -v 07 -h false", 20 | "format:schemas": "replace-in-file --configFile=src/types/schemas/configs/replace-ref-config.ts && replace-in-file --configFile=src/types/schemas/configs/replace-undefined-config.ts" 21 | }, 22 | "keywords": [ 23 | "Defender", 24 | "Serverless", 25 | "OpenZeppelin", 26 | "Deployment", 27 | "Management", 28 | "Plugin" 29 | ], 30 | "repository": { 31 | "type": "git", 32 | "url": "git+https://github.com/OpenZeppelin/defender-serverless.git" 33 | }, 34 | "contributors": [ 35 | { 36 | "name": "Santiago Palladino", 37 | "email": "santiago@openzeppelin.com" 38 | }, 39 | { 40 | "name": "Nami Shah", 41 | "email": "nami@openzeppelin.com" 42 | } 43 | ], 44 | "license": "MIT", 45 | "bugs": { 46 | "url": "https://github.com/OpenZeppelin/defender-serverless/issues" 47 | }, 48 | "homepage": "https://github.com/OpenZeppelin/defender-serverless#readme", 49 | "devDependencies": { 50 | "@adobe/jsonschema2md": "^7.1.1", 51 | "@types/eslint": "^8.4.6", 52 | "@types/lodash": "^4.14.184", 53 | "@types/node": "^18.7.14", 54 | "@types/prompt": "^1.1.3", 55 | "@types/serverless": "^3.12.8", 56 | "@typescript-eslint/eslint-plugin": "^5.36.2", 57 | "@typescript-eslint/parser": "^5.36.2", 58 | "code-style": "https://github.com/OpenZeppelin/code-style.git", 59 | "eslint": "^8.23.0", 60 | "eslint-config-prettier": "^8.6.0", 61 | "eslint-plugin-prettier": "^4.2.1", 62 | "prettier": "^2.7.1", 63 | "replace-in-file": "^6.3.5", 64 | "typescript": "^4.9.5" 65 | }, 66 | "dependencies": { 67 | "@openzeppelin/defender-admin-client": "^1.48.0", 68 | "@openzeppelin/defender-autotask-client": "^1.48.0", 69 | "@openzeppelin/defender-relay-client": "^1.48.0", 70 | "@openzeppelin/defender-sentinel-client": "^1.48.0", 71 | "@openzeppelin/platform-deploy-client": "^0.10.0", 72 | "keccak256": "^1.0.6", 73 | "lodash": "^4.17.21", 74 | "prompt": "^1.3.0" 75 | }, 76 | "files": [ 77 | "lib", 78 | "!*.test.js", 79 | "!*.test.js.map", 80 | "!*.test.d.ts", 81 | "!*__mocks__" 82 | ] 83 | } 84 | -------------------------------------------------------------------------------- /src/cmd/info.ts: -------------------------------------------------------------------------------- 1 | import Serverless from 'serverless'; 2 | import _ from 'lodash'; 3 | 4 | import { Logging } from 'serverless/classes/Plugin'; 5 | 6 | import Logger from '../utils/logger'; 7 | 8 | import { 9 | getAdminClient, 10 | getAutotaskClient, 11 | getConsolidatedSecrets, 12 | getRelayClient, 13 | getSentinelClient, 14 | getStackName, 15 | getTeamAPIkeysOrThrow, 16 | isTemplateResource, 17 | } from '../utils'; 18 | import { 19 | DefenderAutotask, 20 | DefenderCategory, 21 | DefenderContract, 22 | DefenderNotification, 23 | DefenderRelayer, 24 | DefenderRelayerApiKey, 25 | DefenderSentinel, 26 | ResourceType, 27 | TeamKey, 28 | YAutotask, 29 | YCategory, 30 | YContract, 31 | YNotification, 32 | YRelayer, 33 | YSecret, 34 | YSentinel, 35 | } from '../types'; 36 | 37 | export default class DefenderInfo { 38 | serverless: Serverless; 39 | options: Serverless.Options; 40 | logging: Logging; 41 | log: Logger; 42 | hooks: any; 43 | teamKey?: TeamKey; 44 | 45 | constructor(serverless: Serverless, options: Serverless.Options, logging: Logging) { 46 | this.serverless = serverless; 47 | this.options = options; 48 | this.logging = logging; 49 | 50 | this.log = Logger.getInstance(); 51 | 52 | this.hooks = { 53 | 'before:info:info': () => this.validateKeys(), 54 | 'info:info': this.info.bind(this), 55 | }; 56 | } 57 | 58 | validateKeys() { 59 | this.teamKey = getTeamAPIkeysOrThrow(this.serverless); 60 | } 61 | 62 | private async wrapper( 63 | context: Serverless, 64 | resourceType: ResourceType, 65 | resources: Y[] | undefined, 66 | retrieveExistingResources: () => Promise, 67 | format: (resource: D) => string, 68 | output: any[], 69 | ) { 70 | try { 71 | this.log.progress('component-info', `Retrieving ${resourceType}`); 72 | this.log.notice(`${resourceType}`); 73 | const existing = (await retrieveExistingResources()).filter(e => 74 | isTemplateResource(context, e, resourceType, resources ?? []), 75 | ); 76 | 77 | await Promise.all( 78 | existing.map(async e => { 79 | this.log.notice(`${format(e)}`, 1); 80 | let keys: DefenderRelayerApiKey[] = []; 81 | // Also print relayer API keys 82 | if (resourceType === 'Relayers') { 83 | const listRelayerAPIKeys = await getRelayClient(getTeamAPIkeysOrThrow(context)).listKeys( 84 | (e as unknown as DefenderRelayer).relayerId, 85 | ); 86 | listRelayerAPIKeys.map(k => { 87 | this.log.notice(`${k.stackResourceId}: ${k.keyId}`, 2); 88 | }); 89 | keys = listRelayerAPIKeys; 90 | } 91 | if (resourceType === 'Relayers') output.push({ ...e, relayerKeys: keys }); 92 | else output.push(e); 93 | }), 94 | ); 95 | } catch (e) { 96 | this.log.tryLogDefenderError(e); 97 | } 98 | } 99 | 100 | async info() { 101 | this.log.notice('========================================================'); 102 | const stackName = getStackName(this.serverless); 103 | this.log.progress('info', `Running Defender Info on stack: ${stackName}`); 104 | const stdOut = { 105 | stack: stackName, 106 | sentinels: [], 107 | autotasks: [], 108 | contracts: [], 109 | relayers: [], 110 | notifications: [], 111 | categories: [], 112 | secrets: [], 113 | }; 114 | // Sentinels 115 | const listSentinels = () => 116 | getSentinelClient(this.teamKey!) 117 | .list() 118 | .then(i => i.items); 119 | 120 | await this.wrapper( 121 | this.serverless, 122 | 'Sentinels', 123 | this.serverless.service.resources?.Resources?.sentinels, 124 | listSentinels, 125 | (resource: DefenderSentinel) => `${resource.stackResourceId}: ${resource.subscriberId}`, 126 | stdOut.sentinels, 127 | ); 128 | 129 | // Autotasks 130 | const listAutotasks = () => 131 | getAutotaskClient(this.teamKey!) 132 | .list() 133 | .then(r => r.items); 134 | await this.wrapper( 135 | this.serverless, 136 | 'Autotasks', 137 | this.serverless.service.functions as unknown as YAutotask[], 138 | listAutotasks, 139 | (resource: DefenderAutotask) => `${resource.stackResourceId}: ${resource.autotaskId}`, 140 | stdOut.autotasks, 141 | ); 142 | 143 | // Contracts 144 | const listContracts = () => getAdminClient(this.teamKey!).listContracts(); 145 | await this.wrapper( 146 | this.serverless, 147 | 'Contracts', 148 | this.serverless.service.resources?.Resources?.contracts, 149 | listContracts, 150 | (resource: DefenderContract) => `${resource.network}-${resource.address}: ${resource.name}`, 151 | stdOut.contracts, 152 | ); 153 | 154 | // Relayers 155 | const listRelayers = () => 156 | getRelayClient(this.teamKey!) 157 | .list() 158 | .then(r => r.items); 159 | await this.wrapper( 160 | this.serverless, 161 | 'Relayers', 162 | this.serverless.service.resources?.Resources?.relayers, 163 | listRelayers, 164 | (resource: DefenderRelayer) => `${resource.stackResourceId}: ${resource.relayerId}`, 165 | stdOut.relayers, 166 | ); 167 | 168 | // Notifications 169 | const listNotifications = () => getSentinelClient(this.teamKey!).listNotificationChannels(); 170 | await this.wrapper( 171 | this.serverless, 172 | 'Notifications', 173 | this.serverless.service.resources?.Resources?.notifications, 174 | listNotifications, 175 | (resource: DefenderNotification) => `${resource.stackResourceId}: ${resource.notificationId}`, 176 | stdOut.notifications, 177 | ); 178 | 179 | // Categories 180 | const listNotificationCategories = () => getSentinelClient(this.teamKey!).listNotificationCategories(); 181 | await this.wrapper( 182 | this.serverless, 183 | 'Categories', 184 | this.serverless.service.resources?.Resources?.categories, 185 | listNotificationCategories, 186 | (resource: DefenderCategory) => `${resource.stackResourceId}: ${resource.categoryId}`, 187 | stdOut.categories, 188 | ); 189 | 190 | // Secrets 191 | const listSecrets = () => 192 | getAutotaskClient(this.teamKey!) 193 | .listSecrets() 194 | .then(r => r.secretNames ?? []); 195 | 196 | const allSecrets = getConsolidatedSecrets(this.serverless); 197 | 198 | await this.wrapper( 199 | this.serverless, 200 | 'Secrets', 201 | allSecrets, 202 | listSecrets, 203 | (resource: string) => `${resource}`, 204 | stdOut.secrets, 205 | ); 206 | this.log.notice('========================================================'); 207 | if (!process.stdout.isTTY) this.log.stdOut(JSON.stringify(stdOut, null, 2)); 208 | } 209 | } 210 | -------------------------------------------------------------------------------- /src/cmd/invoke.ts: -------------------------------------------------------------------------------- 1 | import Serverless from 'serverless'; 2 | 3 | import { Logging } from 'serverless/classes/Plugin'; 4 | 5 | import Logger from '../utils/logger'; 6 | 7 | import { getAutotaskClient, getEquivalentResourceByKey, getTeamAPIkeysOrThrow } from '../utils'; 8 | import { DefenderAutotask, TeamKey } from '../types'; 9 | 10 | export default class DefenderInvoke { 11 | serverless: Serverless; 12 | options: Serverless.Options; 13 | logging: Logging; 14 | log: Logger; 15 | hooks: any; 16 | teamKey?: TeamKey; 17 | 18 | constructor(serverless: Serverless, options: Serverless.Options, logging: Logging) { 19 | this.serverless = serverless; 20 | this.options = options; 21 | this.logging = logging; 22 | 23 | this.log = Logger.getInstance(); 24 | 25 | this.hooks = { 26 | 'before:invoke:invoke': () => this.validateKeys(), 27 | 'invoke:invoke': this.invoke.bind(this), 28 | }; 29 | } 30 | 31 | validateKeys() { 32 | this.teamKey = getTeamAPIkeysOrThrow(this.serverless); 33 | } 34 | 35 | async invoke() { 36 | try { 37 | this.log.notice('========================================================'); 38 | this.log.progress('logs', `Running Defender Invoke on stack function: ${this.options.function}`); 39 | const payload = JSON.parse((this.options as any)?.data ?? '{}'); 40 | const client = getAutotaskClient(this.teamKey!); 41 | const list = (await client.list()).items; 42 | const defenderAutotask = getEquivalentResourceByKey(this.options.function!, list); 43 | if (defenderAutotask) { 44 | const response = await client.runAutotask(defenderAutotask.autotaskId, payload); 45 | this.log.notice(JSON.stringify(response, null, 2)); 46 | if (!process.stdout.isTTY) this.log.stdOut(JSON.stringify(response, null, 2)); 47 | } else { 48 | this.log.error(`No autotask with identifier: ${this.options.function} found.`); 49 | } 50 | this.log.notice('========================================================'); 51 | } catch (e) { 52 | this.log.tryLogDefenderError(e); 53 | } 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /src/cmd/logs.ts: -------------------------------------------------------------------------------- 1 | import Serverless from 'serverless'; 2 | 3 | import { Logging } from 'serverless/classes/Plugin'; 4 | 5 | import Logger from '../utils/logger'; 6 | 7 | import { tailLogsFor } from '@openzeppelin/defender-autotask-client/lib/utils'; 8 | 9 | import { getAutotaskClient, getEquivalentResourceByKey, getTeamAPIkeysOrThrow } from '../utils'; 10 | import { DefenderAutotask, TeamKey } from '../types'; 11 | 12 | export default class DefenderLogs { 13 | serverless: Serverless; 14 | options: Serverless.Options; 15 | logging: Logging; 16 | log: Logger; 17 | hooks: any; 18 | teamKey?: TeamKey; 19 | 20 | constructor(serverless: Serverless, options: Serverless.Options, logging: Logging) { 21 | this.serverless = serverless; 22 | this.options = options; 23 | this.logging = logging; 24 | 25 | this.log = Logger.getInstance(); 26 | 27 | this.hooks = { 28 | 'before:logs:logs': () => this.validateKeys(), 29 | 'logs:logs': this.logs.bind(this), 30 | }; 31 | } 32 | 33 | validateKeys() { 34 | this.teamKey = getTeamAPIkeysOrThrow(this.serverless); 35 | } 36 | 37 | async logs() { 38 | try { 39 | this.log.notice('========================================================'); 40 | this.log.progress('logs', `Running Defender Logs on stack function: ${this.options.function}`); 41 | const client = getAutotaskClient(this.teamKey!); 42 | const list = (await client.list()).items; 43 | 44 | const defenderAutotask = getEquivalentResourceByKey(this.options.function!, list); 45 | 46 | if (defenderAutotask) await tailLogsFor(client, defenderAutotask!.autotaskId); 47 | else this.log.error(`No autotask with stackResourceId: ${this.options.function} found.`); 48 | this.log.notice('========================================================'); 49 | } catch (e) { 50 | this.log.tryLogDefenderError(e); 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | import Serverless from 'serverless'; 2 | 3 | import { Logging } from 'serverless/classes/Plugin'; 4 | 5 | import DefenderProvider from './provider'; 6 | import DefenderDeploy from './cmd/deploy'; 7 | import DefenderInfo from './cmd/info'; 8 | import DefenderRemove from './cmd/remove'; 9 | import DefenderLogs from './cmd/logs'; 10 | import DefenderInvoke from './cmd/invoke'; 11 | 12 | import Logger from './utils/logger'; 13 | 14 | class DefenderPlugin { 15 | serverless: Serverless; 16 | options: Serverless.Options; 17 | logging: Logging; 18 | constructor(serverless: Serverless, options: Serverless.Options, logging: Logging) { 19 | this.serverless = serverless; 20 | this.options = options; 21 | this.logging = logging; 22 | 23 | Logger.getInstance(logging); 24 | 25 | this.serverless.setProvider('defender', new DefenderProvider(this.serverless) as any); 26 | this.serverless.pluginManager.addPlugin(DefenderDeploy); 27 | this.serverless.pluginManager.addPlugin(DefenderInfo); 28 | this.serverless.pluginManager.addPlugin(DefenderRemove); 29 | this.serverless.pluginManager.addPlugin(DefenderLogs); 30 | this.serverless.pluginManager.addPlugin(DefenderInvoke); 31 | } 32 | } 33 | 34 | module.exports = DefenderPlugin; 35 | -------------------------------------------------------------------------------- /src/provider.ts: -------------------------------------------------------------------------------- 1 | import Serverless from 'serverless'; 2 | 3 | import { DefenderSchema, DefinitionsSchema, ResourcesSchema, FunctionSchema, ProviderSchema } from './types/schemas'; 4 | 5 | export default class DefenderProvider { 6 | constructor(serverless: Serverless) { 7 | serverless.configSchemaHandler.defineTopLevelProperty('defender', DefenderSchema); 8 | serverless.configSchemaHandler.defineProvider('defender', { 9 | definitions: DefinitionsSchema.definitions, 10 | provider: ProviderSchema, 11 | resources: ResourcesSchema, 12 | function: FunctionSchema, 13 | }); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/types/docs-schemas/defender.schema.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "title": "Defender", 4 | "type": "object", 5 | "properties": { 6 | "key": { "type": "string" }, 7 | "secret": { "type": "string" } 8 | }, 9 | "required": ["key", "secret"] 10 | } 11 | -------------------------------------------------------------------------------- /src/types/docs-schemas/function.schema.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "title": "Function", 4 | "type": "object", 5 | "properties": { 6 | "path": { "type": "string" }, 7 | "relayer": { 8 | "title": "Relayer", 9 | "$ref": "definitions.schema.json/#/definitions/relayer", 10 | "format": "uri-reference" 11 | }, 12 | "trigger": { 13 | "title": "Trigger", 14 | "type": "object", 15 | "properties": { 16 | "type": { 17 | "title": "TriggerType", 18 | "type": "string", 19 | "enum": ["schedule", "webhook", "sentinel", "monitor-filter"] 20 | }, 21 | "cron": { "title": "TriggerCron", "type": "string" }, 22 | "frequency": { "title": "TriggerFrequency", "type": "integer" } 23 | }, 24 | "if": { 25 | "properties": { "type": { "const": "schedule" } } 26 | }, 27 | "then": { 28 | "oneOf": [ 29 | { 30 | "required": ["cron"] 31 | }, 32 | { 33 | "required": ["frequency"] 34 | } 35 | ] 36 | }, 37 | "else": {}, 38 | "required": ["type"] 39 | }, 40 | "paused": { "type": "boolean" } 41 | }, 42 | "required": ["name", "path", "trigger", "paused"] 43 | } 44 | -------------------------------------------------------------------------------- /src/types/docs-schemas/provider.schema.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "title": "Provider", 4 | "type": "object", 5 | "properties": { 6 | "stage": { "type": "string" }, 7 | "stackName": { "type": "string" }, 8 | "ssot": { "type": "boolean" } 9 | }, 10 | "required": ["stage", "stackName"] 11 | } 12 | -------------------------------------------------------------------------------- /src/types/docs-schemas/resources.schema.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-07/schema#", 3 | "title": "Resources", 4 | "type": "object", 5 | "additionalProperties": false, 6 | "properties": { 7 | "Resources": { 8 | "title": "Resources", 9 | "type": "object", 10 | "properties": { 11 | "notifications": { 12 | "title": "Notifications", 13 | "type": "object", 14 | "additionalProperties": { 15 | "$ref": "definitions.schema.json/#/definitions/notification", 16 | "format": "uri-reference" 17 | } 18 | }, 19 | "relayers": { 20 | "title": "Relayers", 21 | "type": "object", 22 | "additionalProperties": { 23 | "$ref": "definitions.schema.json/#/definitions/relayer", 24 | "format": "uri-reference" 25 | } 26 | }, 27 | "policies": { 28 | "title": "Policies", 29 | "type": "object", 30 | "additionalProperties": { 31 | "$ref": "definitions.schema.json/#/definitions/policy", 32 | "format": "uri-reference" 33 | } 34 | }, 35 | "contracts": { 36 | "title": "Contracts", 37 | "type": "object", 38 | "additionalProperties": { 39 | "$ref": "definitions.schema.json/#/definitions/contract", 40 | "format": "uri-reference" 41 | } 42 | }, 43 | "secrets": { 44 | "title": "AutotaskSecrets", 45 | "type": "object", 46 | "additionalProperties": false, 47 | "properties": { 48 | "global": { "title": "Global", "type": "object", "additionalProperties": { "type": "string" } }, 49 | "stack": { "title": "Stack", "type": "object", "additionalProperties": { "type": "string" } } 50 | } 51 | }, 52 | "sentinels": { 53 | "title": "Sentinels", 54 | "type": "object", 55 | "additionalProperties": { 56 | "$ref": "definitions.schema.json/#/definitions/sentinel", 57 | "format": "uri-reference" 58 | } 59 | }, 60 | "deployment-configs": { 61 | "title": "Deployment Configs", 62 | "type": "object", 63 | "additionalProperties": { 64 | "$ref": "definitions.schema.json/#/definitions/deploymentConfig", 65 | "format": "uri-reference" 66 | } 67 | }, 68 | "block-explorer-api-keys": { 69 | "title": "Block Explorer Api Keys", 70 | "type": "object", 71 | "additionalProperties": { 72 | "$ref": "definitions.schema.json/#/definitions/blockExplorerApiKey", 73 | "format": "uri-reference" 74 | } 75 | } 76 | } 77 | } 78 | } 79 | } 80 | -------------------------------------------------------------------------------- /src/types/docs/defender-properties-key.md: -------------------------------------------------------------------------------- 1 | ## key Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/defender-properties-secret.md: -------------------------------------------------------------------------------- 1 | ## secret Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/defender.md: -------------------------------------------------------------------------------- 1 | ## Defender Type 2 | 3 | `object` ([Defender](defender.md)) 4 | 5 | # Defender Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :---------------- | :------- | :------- | :------------- | :----------------------------------------------------------------------- | 9 | | [key](#key) | `string` | Required | cannot be null | [Defender](defender-properties-key.md "#/properties/key") | 10 | | [secret](#secret) | `string` | Required | cannot be null | [Defender](defender-properties-secret.md "#/properties/secret") | 11 | 12 | ## key 13 | 14 | 15 | 16 | `key` 17 | 18 | * is required 19 | 20 | * Type: `string` 21 | 22 | * cannot be null 23 | 24 | * defined in: [Defender](defender-properties-key.md "#/properties/key") 25 | 26 | ### key Type 27 | 28 | `string` 29 | 30 | ## secret 31 | 32 | 33 | 34 | `secret` 35 | 36 | * is required 37 | 38 | * Type: `string` 39 | 40 | * cannot be null 41 | 42 | * defined in: [Defender](defender-properties-secret.md "#/properties/secret") 43 | 44 | ### secret Type 45 | 46 | `string` 47 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-abitype-anyof-arrayabi.md: -------------------------------------------------------------------------------- 1 | ## 1 Type 2 | 3 | `array` ([ArrayABI](definitions-definitions-abitype-anyof-arrayabi.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-abitype-anyof-stringabi.md: -------------------------------------------------------------------------------- 1 | ## 0 Type 2 | 3 | `string` ([StringABI](definitions-definitions-abitype-anyof-stringabi.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-abitype.md: -------------------------------------------------------------------------------- 1 | ## abi Type 2 | 3 | merged type ([AbiType](definitions-definitions-abitype.md)) 4 | 5 | any of 6 | 7 | * [StringABI](definitions-definitions-abitype-anyof-stringabi.md "check type definition") 8 | 9 | * [ArrayABI](definitions-definitions-abitype-anyof-arrayabi.md "check type definition") 10 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-address.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` ([Address](definitions-definitions-address.md)) 4 | 5 | ## items Constraints 6 | 7 | **pattern**: the string must match the following regular expression: 8 | 9 | ```regexp 10 | ^0x[a-fA-F0-9]{40}$ 11 | ``` 12 | 13 | [try pattern](https://regexr.com/?expression=%5E0x%5Ba-fA-F0-9%5D%7B40%7D%24 "try regular expression with regexr.com") 14 | 15 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 16 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-name.md: -------------------------------------------------------------------------------- 1 | ## name Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-path.md: -------------------------------------------------------------------------------- 1 | ## path Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-paused.md: -------------------------------------------------------------------------------- 1 | ## paused Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-else.md: -------------------------------------------------------------------------------- 1 | ## else Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-if-properties-type.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | unknown 4 | 5 | ## type Constraints 6 | 7 | **constant**: the value of this property must be equal to: 8 | 9 | ```json 10 | "schedule" 11 | ``` 12 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-if-properties.md: -------------------------------------------------------------------------------- 1 | ## properties Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-if.md: -------------------------------------------------------------------------------- 1 | ## if Type 2 | 3 | unknown 4 | 5 | # if Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :------------ | :------------ | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [type](#type) | Not specified | Optional | cannot be null | [Definitions](definitions-definitions-autotask-properties-trigger-if-properties-type.md "#/definitions/autotask/properties/trigger/if/properties/type") | 10 | 11 | ## type 12 | 13 | 14 | 15 | `type` 16 | 17 | * is optional 18 | 19 | * Type: unknown 20 | 21 | * cannot be null 22 | 23 | * defined in: [Definitions](definitions-definitions-autotask-properties-trigger-if-properties-type.md "#/definitions/autotask/properties/trigger/if/properties/type") 24 | 25 | ### type Type 26 | 27 | unknown 28 | 29 | ### type Constraints 30 | 31 | **constant**: the value of this property must be equal to: 32 | 33 | ```json 34 | "schedule" 35 | ``` 36 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-properties-triggercron.md: -------------------------------------------------------------------------------- 1 | ## cron Type 2 | 3 | `string` ([TriggerCron](definitions-definitions-autotask-properties-trigger-properties-triggercron.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-properties-triggerfrequency.md: -------------------------------------------------------------------------------- 1 | ## frequency Type 2 | 3 | `integer` ([TriggerFrequency](definitions-definitions-autotask-properties-trigger-properties-triggerfrequency.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-properties-triggertype.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | `string` ([TriggerType](definitions-definitions-autotask-properties-trigger-properties-triggertype.md)) 4 | 5 | ## type Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :----------------- | :---------- | 11 | | `"schedule"` | | 12 | | `"webhook"` | | 13 | | `"sentinel"` | | 14 | | `"monitor-filter"` | | 15 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-then-oneof-0.md: -------------------------------------------------------------------------------- 1 | ## 0 Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-then-oneof-1.md: -------------------------------------------------------------------------------- 1 | ## 1 Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger-then.md: -------------------------------------------------------------------------------- 1 | ## then Type 2 | 3 | merged type ([Details](definitions-definitions-autotask-properties-trigger-then.md)) 4 | 5 | one (and only one) of 6 | 7 | * [Untitled type in Definitions](definitions-definitions-autotask-properties-trigger-then-oneof-0.md "check type definition") 8 | 9 | * [Untitled type in Definitions](definitions-definitions-autotask-properties-trigger-then-oneof-1.md "check type definition") 10 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask-properties-trigger.md: -------------------------------------------------------------------------------- 1 | ## trigger Type 2 | 3 | `object` ([Trigger](definitions-definitions-autotask-properties-trigger.md)) 4 | 5 | # trigger Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :---------------------- | :-------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [type](#type) | `string` | Required | cannot be null | [Definitions](definitions-definitions-autotask-properties-trigger-properties-triggertype.md "#/definitions/autotask/properties/trigger/properties/type") | 10 | | [cron](#cron) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-autotask-properties-trigger-properties-triggercron.md "#/definitions/autotask/properties/trigger/properties/cron") | 11 | | [frequency](#frequency) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-autotask-properties-trigger-properties-triggerfrequency.md "#/definitions/autotask/properties/trigger/properties/frequency") | 12 | 13 | ## type 14 | 15 | 16 | 17 | `type` 18 | 19 | * is required 20 | 21 | * Type: `string` ([TriggerType](definitions-definitions-autotask-properties-trigger-properties-triggertype.md)) 22 | 23 | * cannot be null 24 | 25 | * defined in: [Definitions](definitions-definitions-autotask-properties-trigger-properties-triggertype.md "#/definitions/autotask/properties/trigger/properties/type") 26 | 27 | ### type Type 28 | 29 | `string` ([TriggerType](definitions-definitions-autotask-properties-trigger-properties-triggertype.md)) 30 | 31 | ### type Constraints 32 | 33 | **enum**: the value of this property must be equal to one of the following values: 34 | 35 | | Value | Explanation | 36 | | :----------------- | :---------- | 37 | | `"schedule"` | | 38 | | `"webhook"` | | 39 | | `"sentinel"` | | 40 | | `"monitor-filter"` | | 41 | 42 | ## cron 43 | 44 | 45 | 46 | `cron` 47 | 48 | * is optional 49 | 50 | * Type: `string` ([TriggerCron](definitions-definitions-autotask-properties-trigger-properties-triggercron.md)) 51 | 52 | * cannot be null 53 | 54 | * defined in: [Definitions](definitions-definitions-autotask-properties-trigger-properties-triggercron.md "#/definitions/autotask/properties/trigger/properties/cron") 55 | 56 | ### cron Type 57 | 58 | `string` ([TriggerCron](definitions-definitions-autotask-properties-trigger-properties-triggercron.md)) 59 | 60 | ## frequency 61 | 62 | 63 | 64 | `frequency` 65 | 66 | * is optional 67 | 68 | * Type: `integer` ([TriggerFrequency](definitions-definitions-autotask-properties-trigger-properties-triggerfrequency.md)) 69 | 70 | * cannot be null 71 | 72 | * defined in: [Definitions](definitions-definitions-autotask-properties-trigger-properties-triggerfrequency.md "#/definitions/autotask/properties/trigger/properties/frequency") 73 | 74 | ### frequency Type 75 | 76 | `integer` ([TriggerFrequency](definitions-definitions-autotask-properties-trigger-properties-triggerfrequency.md)) 77 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-autotask.md: -------------------------------------------------------------------------------- 1 | ## autotask Type 2 | 3 | `object` ([Autotask](definitions-definitions-autotask.md)) 4 | 5 | # autotask Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :------------------ | :-------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------- | 9 | | [name](#name) | `string` | Required | cannot be null | [Definitions](definitions-definitions-autotask-properties-name.md "#/definitions/autotask/properties/name") | 10 | | [path](#path) | `string` | Required | cannot be null | [Definitions](definitions-definitions-autotask-properties-path.md "#/definitions/autotask/properties/path") | 11 | | [relayer](#relayer) | `object` | Optional | cannot be null | [Definitions](definitions-definitions-relayer.md "#/definitions/autotask/properties/relayer") | 12 | | [trigger](#trigger) | `object` | Required | cannot be null | [Definitions](definitions-definitions-autotask-properties-trigger.md "#/definitions/autotask/properties/trigger") | 13 | | [paused](#paused) | `boolean` | Required | cannot be null | [Definitions](definitions-definitions-autotask-properties-paused.md "#/definitions/autotask/properties/paused") | 14 | 15 | ## name 16 | 17 | 18 | 19 | `name` 20 | 21 | * is required 22 | 23 | * Type: `string` 24 | 25 | * cannot be null 26 | 27 | * defined in: [Definitions](definitions-definitions-autotask-properties-name.md "#/definitions/autotask/properties/name") 28 | 29 | ### name Type 30 | 31 | `string` 32 | 33 | ## path 34 | 35 | 36 | 37 | `path` 38 | 39 | * is required 40 | 41 | * Type: `string` 42 | 43 | * cannot be null 44 | 45 | * defined in: [Definitions](definitions-definitions-autotask-properties-path.md "#/definitions/autotask/properties/path") 46 | 47 | ### path Type 48 | 49 | `string` 50 | 51 | ## relayer 52 | 53 | 54 | 55 | `relayer` 56 | 57 | * is optional 58 | 59 | * Type: `object` ([Relayer](definitions-definitions-relayer.md)) 60 | 61 | * cannot be null 62 | 63 | * defined in: [Definitions](definitions-definitions-relayer.md "#/definitions/autotask/properties/relayer") 64 | 65 | ### relayer Type 66 | 67 | `object` ([Relayer](definitions-definitions-relayer.md)) 68 | 69 | ### relayer Constraints 70 | 71 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 72 | 73 | ## trigger 74 | 75 | 76 | 77 | `trigger` 78 | 79 | * is required 80 | 81 | * Type: `object` ([Trigger](definitions-definitions-autotask-properties-trigger.md)) 82 | 83 | * cannot be null 84 | 85 | * defined in: [Definitions](definitions-definitions-autotask-properties-trigger.md "#/definitions/autotask/properties/trigger") 86 | 87 | ### trigger Type 88 | 89 | `object` ([Trigger](definitions-definitions-autotask-properties-trigger.md)) 90 | 91 | ## paused 92 | 93 | 94 | 95 | `paused` 96 | 97 | * is required 98 | 99 | * Type: `boolean` 100 | 101 | * cannot be null 102 | 103 | * defined in: [Definitions](definitions-definitions-autotask-properties-paused.md "#/definitions/autotask/properties/paused") 104 | 105 | ### paused Type 106 | 107 | `boolean` 108 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blockexplorerapikey-properties-key.md: -------------------------------------------------------------------------------- 1 | ## key Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blockexplorerapikey.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `object` ([BlockExplorerApiKey](definitions-definitions-blockexplorerapikey.md)) 4 | 5 | ## additionalProperties Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # additionalProperties Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :------------------ | :------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------------------- | 13 | | [key](#key) | `string` | Required | cannot be null | [Definitions](definitions-definitions-blockexplorerapikey-properties-key.md "#/definitions/blockExplorerApiKey/properties/key") | 14 | | [network](#network) | `string` | Required | cannot be null | [Definitions](definitions-definitions-network.md "#/definitions/blockExplorerApiKey/properties/network") | 15 | 16 | ## key 17 | 18 | 19 | 20 | `key` 21 | 22 | * is required 23 | 24 | * Type: `string` 25 | 26 | * cannot be null 27 | 28 | * defined in: [Definitions](definitions-definitions-blockexplorerapikey-properties-key.md "#/definitions/blockExplorerApiKey/properties/key") 29 | 30 | ### key Type 31 | 32 | `string` 33 | 34 | ## network 35 | 36 | 37 | 38 | `network` 39 | 40 | * is required 41 | 42 | * Type: `string` ([Network](definitions-definitions-network.md)) 43 | 44 | * cannot be null 45 | 46 | * defined in: [Definitions](definitions-definitions-network.md "#/definitions/blockExplorerApiKey/properties/network") 47 | 48 | ### network Type 49 | 50 | `string` ([Network](definitions-definitions-network.md)) 51 | 52 | ### network Constraints 53 | 54 | **enum**: the value of this property must be equal to one of the following values: 55 | 56 | | Value | Explanation | 57 | | :------------------------ | :---------- | 58 | | `"alfajores"` | | 59 | | `"amoy"` | | 60 | | `"arbitrum"` | | 61 | | `"arbitrum-nova"` | | 62 | | `"arbitrum-rinkeby"` | | 63 | | `"aurora"` | | 64 | | `"auroratest"` | | 65 | | `"avalanche"` | | 66 | | `"base"` | | 67 | | `"bsc"` | | 68 | | `"bsctest"` | | 69 | | `"celo"` | | 70 | | `"fantom"` | | 71 | | `"fantomtest"` | | 72 | | `"fuji"` | | 73 | | `"fuse"` | | 74 | | `"harmony-s0"` | | 75 | | `"harmony-test-s0"` | | 76 | | `"hedera"` | | 77 | | `"hederatest"` | | 78 | | `"kovan"` | | 79 | | `"linea"` | | 80 | | `"linea-goerli"` | | 81 | | `"mainnet"` | | 82 | | `"matic"` | | 83 | | `"moonbase"` | | 84 | | `"moonbeam"` | | 85 | | `"moonriver"` | | 86 | | `"mumbai"` | | 87 | | `"optimism"` | | 88 | | `"optimism-kovan"` | | 89 | | `"rinkeby"` | | 90 | | `"ropsten"` | | 91 | | `"sepolia"` | | 92 | | `"sokol"` | | 93 | | `"x-dfk-avax-chain"` | | 94 | | `"x-dfk-avax-chain-test"` | | 95 | | `"xdai"` | | 96 | | `"zksync"` | | 97 | 98 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 99 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-addresses.md: -------------------------------------------------------------------------------- 1 | ## addresses Type 2 | 3 | `string[]` ([Address](definitions-definitions-address.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-alertthreshold-properties-amount.md: -------------------------------------------------------------------------------- 1 | ## amount Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-alertthreshold-properties-window-seconds.md: -------------------------------------------------------------------------------- 1 | ## window-seconds Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-alertthreshold.md: -------------------------------------------------------------------------------- 1 | ## alert-threshold Type 2 | 3 | `object` ([AlertThreshold](definitions-definitions-blocksentinel-properties-alertthreshold.md)) 4 | 5 | # alert-threshold Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------------------- | :-------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | 9 | | [amount](#amount) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-alertthreshold-properties-amount.md "#/definitions/blockSentinel/properties/alert-threshold/properties/amount") | 10 | | [window-seconds](#window-seconds) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-alertthreshold-properties-window-seconds.md "#/definitions/blockSentinel/properties/alert-threshold/properties/window-seconds") | 11 | 12 | ## amount 13 | 14 | 15 | 16 | `amount` 17 | 18 | * is optional 19 | 20 | * Type: `integer` 21 | 22 | * cannot be null 23 | 24 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-alertthreshold-properties-amount.md "#/definitions/blockSentinel/properties/alert-threshold/properties/amount") 25 | 26 | ### amount Type 27 | 28 | `integer` 29 | 30 | ## window-seconds 31 | 32 | 33 | 34 | `window-seconds` 35 | 36 | * is optional 37 | 38 | * Type: `integer` 39 | 40 | * cannot be null 41 | 42 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-alertthreshold-properties-window-seconds.md "#/definitions/blockSentinel/properties/alert-threshold/properties/window-seconds") 43 | 44 | ### window-seconds Type 45 | 46 | `integer` 47 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-expression.md: -------------------------------------------------------------------------------- 1 | ## expression Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-signature.md: -------------------------------------------------------------------------------- 1 | ## signature Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `object` ([EventItems](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems.md)) 4 | 5 | # items Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :------------------------ | :------- | :------- | :------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [signature](#signature) | `string` | Required | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-signature.md "#/definitions/blockSentinel/properties/conditions/properties/event/items/properties/signature") | 10 | | [expression](#expression) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-expression.md "#/definitions/blockSentinel/properties/conditions/properties/event/items/properties/expression") | 11 | 12 | ## signature 13 | 14 | 15 | 16 | `signature` 17 | 18 | * is required 19 | 20 | * Type: `string` 21 | 22 | * cannot be null 23 | 24 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-signature.md "#/definitions/blockSentinel/properties/conditions/properties/event/items/properties/signature") 25 | 26 | ### signature Type 27 | 28 | `string` 29 | 30 | ## expression 31 | 32 | 33 | 34 | `expression` 35 | 36 | * is optional 37 | 38 | * Type: `string` 39 | 40 | * cannot be null 41 | 42 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems-properties-expression.md "#/definitions/blockSentinel/properties/conditions/properties/event/items/properties/expression") 43 | 44 | ### expression Type 45 | 46 | `string` 47 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-event.md: -------------------------------------------------------------------------------- 1 | ## event Type 2 | 3 | `object[]` ([EventItems](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-expression.md: -------------------------------------------------------------------------------- 1 | ## expression Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-signature.md: -------------------------------------------------------------------------------- 1 | ## signature Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `object` ([FunctionItems](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems.md)) 4 | 5 | # items Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :------------------------ | :------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [signature](#signature) | `string` | Required | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-signature.md "#/definitions/blockSentinel/properties/conditions/properties/function/items/properties/signature") | 10 | | [expression](#expression) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-expression.md "#/definitions/blockSentinel/properties/conditions/properties/function/items/properties/expression") | 11 | 12 | ## signature 13 | 14 | 15 | 16 | `signature` 17 | 18 | * is required 19 | 20 | * Type: `string` 21 | 22 | * cannot be null 23 | 24 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-signature.md "#/definitions/blockSentinel/properties/conditions/properties/function/items/properties/signature") 25 | 26 | ### signature Type 27 | 28 | `string` 29 | 30 | ## expression 31 | 32 | 33 | 34 | `expression` 35 | 36 | * is optional 37 | 38 | * Type: `string` 39 | 40 | * cannot be null 41 | 42 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems-properties-expression.md "#/definitions/blockSentinel/properties/conditions/properties/function/items/properties/expression") 43 | 44 | ### expression Type 45 | 46 | `string` 47 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-function.md: -------------------------------------------------------------------------------- 1 | ## function Type 2 | 3 | `object[]` ([FunctionItems](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions-properties-transaction.md: -------------------------------------------------------------------------------- 1 | ## transaction Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-conditions.md: -------------------------------------------------------------------------------- 1 | ## conditions Type 2 | 3 | `object` ([Conditions](definitions-definitions-blocksentinel-properties-conditions.md)) 4 | 5 | # conditions Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------------- | :------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [event](#event) | `array` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-event.md "#/definitions/blockSentinel/properties/conditions/properties/event") | 10 | | [function](#function) | `array` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-function.md "#/definitions/blockSentinel/properties/conditions/properties/function") | 11 | | [transaction](#transaction) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-transaction.md "#/definitions/blockSentinel/properties/conditions/properties/transaction") | 12 | 13 | ## event 14 | 15 | 16 | 17 | `event` 18 | 19 | * is optional 20 | 21 | * Type: `object[]` ([EventItems](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems.md)) 22 | 23 | * cannot be null 24 | 25 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-event.md "#/definitions/blockSentinel/properties/conditions/properties/event") 26 | 27 | ### event Type 28 | 29 | `object[]` ([EventItems](definitions-definitions-blocksentinel-properties-conditions-properties-event-eventitems.md)) 30 | 31 | ## function 32 | 33 | 34 | 35 | `function` 36 | 37 | * is optional 38 | 39 | * Type: `object[]` ([FunctionItems](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems.md)) 40 | 41 | * cannot be null 42 | 43 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-function.md "#/definitions/blockSentinel/properties/conditions/properties/function") 44 | 45 | ### function Type 46 | 47 | `object[]` ([FunctionItems](definitions-definitions-blocksentinel-properties-conditions-properties-function-functionitems.md)) 48 | 49 | ## transaction 50 | 51 | 52 | 53 | `transaction` 54 | 55 | * is optional 56 | 57 | * Type: `string` 58 | 59 | * cannot be null 60 | 61 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-conditions-properties-transaction.md "#/definitions/blockSentinel/properties/conditions/properties/transaction") 62 | 63 | ### transaction Type 64 | 65 | `string` 66 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-confirm-level-oneof-0.md: -------------------------------------------------------------------------------- 1 | ## 0 Type 2 | 3 | `string` 4 | 5 | ## 0 Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :------------ | :---------- | 11 | | `"safe"` | | 12 | | `"finalized"` | | 13 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-confirm-level-oneof-1.md: -------------------------------------------------------------------------------- 1 | ## 1 Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-confirm-level.md: -------------------------------------------------------------------------------- 1 | ## confirm-level Type 2 | 3 | merged type ([Details](definitions-definitions-blocksentinel-properties-confirm-level.md)) 4 | 5 | one (and only one) of 6 | 7 | * [Untitled string in Definitions](definitions-definitions-blocksentinel-properties-confirm-level-oneof-0.md "check type definition") 8 | 9 | * [Untitled integer in Definitions](definitions-definitions-blocksentinel-properties-confirm-level-oneof-1.md "check type definition") 10 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-name.md: -------------------------------------------------------------------------------- 1 | ## name Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-notifyconfig-properties-channels.md: -------------------------------------------------------------------------------- 1 | ## channels Type 2 | 3 | `object[]` ([Notification](definitions-definitions-notification.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-notifyconfig-properties-message.md: -------------------------------------------------------------------------------- 1 | ## message Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-notifyconfig-properties-timeout.md: -------------------------------------------------------------------------------- 1 | ## timeout Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-notifyconfig.md: -------------------------------------------------------------------------------- 1 | ## notify-config Type 2 | 3 | `object` ([NotifyConfig](definitions-definitions-blocksentinel-properties-notifyconfig.md)) 4 | 5 | # notify-config Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :-------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [timeout](#timeout) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-notifyconfig-properties-timeout.md "#/definitions/blockSentinel/properties/notify-config/properties/timeout") | 10 | | [message](#message) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-notifyconfig-properties-message.md "#/definitions/blockSentinel/properties/notify-config/properties/message") | 11 | | [category](#category) | `object` | Optional | cannot be null | [Definitions](definitions-definitions-category.md "#/definitions/blockSentinel/properties/notify-config/properties/category") | 12 | | [channels](#channels) | `array` | Required | cannot be null | [Definitions](definitions-definitions-blocksentinel-properties-notifyconfig-properties-channels.md "#/definitions/blockSentinel/properties/notify-config/properties/channels") | 13 | 14 | ## timeout 15 | 16 | 17 | 18 | `timeout` 19 | 20 | * is optional 21 | 22 | * Type: `integer` 23 | 24 | * cannot be null 25 | 26 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-notifyconfig-properties-timeout.md "#/definitions/blockSentinel/properties/notify-config/properties/timeout") 27 | 28 | ### timeout Type 29 | 30 | `integer` 31 | 32 | ## message 33 | 34 | 35 | 36 | `message` 37 | 38 | * is optional 39 | 40 | * Type: `string` 41 | 42 | * cannot be null 43 | 44 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-notifyconfig-properties-message.md "#/definitions/blockSentinel/properties/notify-config/properties/message") 45 | 46 | ### message Type 47 | 48 | `string` 49 | 50 | ## category 51 | 52 | 53 | 54 | `category` 55 | 56 | * is optional 57 | 58 | * Type: `object` ([Category](definitions-definitions-category.md)) 59 | 60 | * cannot be null 61 | 62 | * defined in: [Definitions](definitions-definitions-category.md "#/definitions/blockSentinel/properties/notify-config/properties/category") 63 | 64 | ### category Type 65 | 66 | `object` ([Category](definitions-definitions-category.md)) 67 | 68 | ### category Constraints 69 | 70 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 71 | 72 | ## channels 73 | 74 | 75 | 76 | `channels` 77 | 78 | * is required 79 | 80 | * Type: `object[]` ([Notification](definitions-definitions-notification.md)) 81 | 82 | * cannot be null 83 | 84 | * defined in: [Definitions](definitions-definitions-blocksentinel-properties-notifyconfig-properties-channels.md "#/definitions/blockSentinel/properties/notify-config/properties/channels") 85 | 86 | ### channels Type 87 | 88 | `object[]` ([Notification](definitions-definitions-notification.md)) 89 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-paused.md: -------------------------------------------------------------------------------- 1 | ## paused Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-blocksentinel-properties-type.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | `string` 4 | 5 | ## type Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :-------- | :---------- | 11 | | `"BLOCK"` | | 12 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-category-properties-description.md: -------------------------------------------------------------------------------- 1 | ## description Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-category-properties-name.md: -------------------------------------------------------------------------------- 1 | ## name Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-category-properties-notificationids.md: -------------------------------------------------------------------------------- 1 | ## notificationIds Type 2 | 3 | `object[]` ([Notification](definitions-definitions-notification.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-category.md: -------------------------------------------------------------------------------- 1 | ## category Type 2 | 3 | `object` ([Category](definitions-definitions-category.md)) 4 | 5 | ## category Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # category Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :---------------------------------- | :------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------------- | 13 | | [name](#name) | `string` | Required | cannot be null | [Definitions](definitions-definitions-category-properties-name.md "#/definitions/category/properties/name") | 14 | | [description](#description) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-category-properties-description.md "#/definitions/category/properties/description") | 15 | | [notificationIds](#notificationids) | `array` | Optional | cannot be null | [Definitions](definitions-definitions-category-properties-notificationids.md "#/definitions/category/properties/notificationIds") | 16 | 17 | ## name 18 | 19 | 20 | 21 | `name` 22 | 23 | * is required 24 | 25 | * Type: `string` 26 | 27 | * cannot be null 28 | 29 | * defined in: [Definitions](definitions-definitions-category-properties-name.md "#/definitions/category/properties/name") 30 | 31 | ### name Type 32 | 33 | `string` 34 | 35 | ## description 36 | 37 | 38 | 39 | `description` 40 | 41 | * is optional 42 | 43 | * Type: `string` 44 | 45 | * cannot be null 46 | 47 | * defined in: [Definitions](definitions-definitions-category-properties-description.md "#/definitions/category/properties/description") 48 | 49 | ### description Type 50 | 51 | `string` 52 | 53 | ## notificationIds 54 | 55 | 56 | 57 | `notificationIds` 58 | 59 | * is optional 60 | 61 | * Type: `object[]` ([Notification](definitions-definitions-notification.md)) 62 | 63 | * cannot be null 64 | 65 | * defined in: [Definitions](definitions-definitions-category-properties-notificationids.md "#/definitions/category/properties/notificationIds") 66 | 67 | ### notificationIds Type 68 | 69 | `object[]` ([Notification](definitions-definitions-notification.md)) 70 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-contract-properties-name.md: -------------------------------------------------------------------------------- 1 | ## name Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-contract-properties-nat-spec.md: -------------------------------------------------------------------------------- 1 | ## nat-spec Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-contract.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `object` ([Contract](definitions-definitions-contract.md)) 4 | 5 | ## additionalProperties Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # additionalProperties Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :-------------------- | :------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------- | 13 | | [name](#name) | `string` | Required | cannot be null | [Definitions](definitions-definitions-contract-properties-name.md "#/definitions/contract/properties/name") | 14 | | [address](#address) | `string` | Required | cannot be null | [Definitions](definitions-definitions-address.md "#/definitions/contract/properties/address") | 15 | | [network](#network) | `string` | Required | cannot be null | [Definitions](definitions-definitions-network.md "#/definitions/contract/properties/network") | 16 | | [abi](#abi) | Merged | Optional | cannot be null | [Definitions](definitions-definitions-abitype.md "#/definitions/contract/properties/abi") | 17 | | [nat-spec](#nat-spec) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-contract-properties-nat-spec.md "#/definitions/contract/properties/nat-spec") | 18 | 19 | ## name 20 | 21 | 22 | 23 | `name` 24 | 25 | * is required 26 | 27 | * Type: `string` 28 | 29 | * cannot be null 30 | 31 | * defined in: [Definitions](definitions-definitions-contract-properties-name.md "#/definitions/contract/properties/name") 32 | 33 | ### name Type 34 | 35 | `string` 36 | 37 | ## address 38 | 39 | 40 | 41 | `address` 42 | 43 | * is required 44 | 45 | * Type: `string` ([Address](definitions-definitions-address.md)) 46 | 47 | * cannot be null 48 | 49 | * defined in: [Definitions](definitions-definitions-address.md "#/definitions/contract/properties/address") 50 | 51 | ### address Type 52 | 53 | `string` ([Address](definitions-definitions-address.md)) 54 | 55 | ### address Constraints 56 | 57 | **pattern**: the string must match the following regular expression: 58 | 59 | ```regexp 60 | ^0x[a-fA-F0-9]{40}$ 61 | ``` 62 | 63 | [try pattern](https://regexr.com/?expression=%5E0x%5Ba-fA-F0-9%5D%7B40%7D%24 "try regular expression with regexr.com") 64 | 65 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 66 | 67 | ## network 68 | 69 | 70 | 71 | `network` 72 | 73 | * is required 74 | 75 | * Type: `string` ([Network](definitions-definitions-network.md)) 76 | 77 | * cannot be null 78 | 79 | * defined in: [Definitions](definitions-definitions-network.md "#/definitions/contract/properties/network") 80 | 81 | ### network Type 82 | 83 | `string` ([Network](definitions-definitions-network.md)) 84 | 85 | ### network Constraints 86 | 87 | **enum**: the value of this property must be equal to one of the following values: 88 | 89 | | Value | Explanation | 90 | | :------------------------ | :---------- | 91 | | `"alfajores"` | | 92 | | `"amoy"` | | 93 | | `"arbitrum"` | | 94 | | `"arbitrum-nova"` | | 95 | | `"arbitrum-rinkeby"` | | 96 | | `"aurora"` | | 97 | | `"auroratest"` | | 98 | | `"avalanche"` | | 99 | | `"base"` | | 100 | | `"bsc"` | | 101 | | `"bsctest"` | | 102 | | `"celo"` | | 103 | | `"fantom"` | | 104 | | `"fantomtest"` | | 105 | | `"fuji"` | | 106 | | `"fuse"` | | 107 | | `"harmony-s0"` | | 108 | | `"harmony-test-s0"` | | 109 | | `"hedera"` | | 110 | | `"hederatest"` | | 111 | | `"kovan"` | | 112 | | `"linea"` | | 113 | | `"linea-goerli"` | | 114 | | `"mainnet"` | | 115 | | `"matic"` | | 116 | | `"moonbase"` | | 117 | | `"moonbeam"` | | 118 | | `"moonriver"` | | 119 | | `"mumbai"` | | 120 | | `"optimism"` | | 121 | | `"optimism-kovan"` | | 122 | | `"rinkeby"` | | 123 | | `"ropsten"` | | 124 | | `"sepolia"` | | 125 | | `"sokol"` | | 126 | | `"x-dfk-avax-chain"` | | 127 | | `"x-dfk-avax-chain-test"` | | 128 | | `"xdai"` | | 129 | | `"zksync"` | | 130 | 131 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 132 | 133 | ## abi 134 | 135 | 136 | 137 | `abi` 138 | 139 | * is optional 140 | 141 | * Type: merged type ([AbiType](definitions-definitions-abitype.md)) 142 | 143 | * cannot be null 144 | 145 | * defined in: [Definitions](definitions-definitions-abitype.md "#/definitions/contract/properties/abi") 146 | 147 | ### abi Type 148 | 149 | merged type ([AbiType](definitions-definitions-abitype.md)) 150 | 151 | any of 152 | 153 | * [StringABI](definitions-definitions-abitype-anyof-stringabi.md "check type definition") 154 | 155 | * [ArrayABI](definitions-definitions-abitype-anyof-arrayabi.md "check type definition") 156 | 157 | ## nat-spec 158 | 159 | 160 | 161 | `nat-spec` 162 | 163 | * is optional 164 | 165 | * Type: `string` 166 | 167 | * cannot be null 168 | 169 | * defined in: [Definitions](definitions-definitions-contract-properties-nat-spec.md "#/definitions/contract/properties/nat-spec") 170 | 171 | ### nat-spec Type 172 | 173 | `string` 174 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-datadogconfig-properties-api-key.md: -------------------------------------------------------------------------------- 1 | ## api-key Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-datadogconfig-properties-metric-prefix.md: -------------------------------------------------------------------------------- 1 | ## metric-prefix Type 2 | 3 | `string` 4 | 5 | ## metric-prefix Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `100` 8 | 9 | **pattern**: the string must match the following regular expression: 10 | 11 | ```regexp 12 | ^[A-Za-z]+[A-Za-z0-9_\.]*\.$ 13 | ``` 14 | 15 | [try pattern](https://regexr.com/?expression=%5E%5BA-Za-z%5D%2B%5BA-Za-z0-9_%5C.%5D*%5C.%24 "try regular expression with regexr.com") 16 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-datadogconfig.md: -------------------------------------------------------------------------------- 1 | ## 2 Type 2 | 3 | `object` ([DatadogConfig](definitions-definitions-datadogconfig.md)) 4 | 5 | ## 2 Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # 2 Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :------------------------------ | :------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------------------- | 13 | | [api-key](#api-key) | `string` | Required | cannot be null | [Definitions](definitions-definitions-datadogconfig-properties-api-key.md "#/definitions/datadogConfig/properties/api-key") | 14 | | [metric-prefix](#metric-prefix) | `string` | Required | cannot be null | [Definitions](definitions-definitions-datadogconfig-properties-metric-prefix.md "#/definitions/datadogConfig/properties/metric-prefix") | 15 | 16 | ## api-key 17 | 18 | 19 | 20 | `api-key` 21 | 22 | * is required 23 | 24 | * Type: `string` 25 | 26 | * cannot be null 27 | 28 | * defined in: [Definitions](definitions-definitions-datadogconfig-properties-api-key.md "#/definitions/datadogConfig/properties/api-key") 29 | 30 | ### api-key Type 31 | 32 | `string` 33 | 34 | ## metric-prefix 35 | 36 | 37 | 38 | `metric-prefix` 39 | 40 | * is required 41 | 42 | * Type: `string` 43 | 44 | * cannot be null 45 | 46 | * defined in: [Definitions](definitions-definitions-datadogconfig-properties-metric-prefix.md "#/definitions/datadogConfig/properties/metric-prefix") 47 | 48 | ### metric-prefix Type 49 | 50 | `string` 51 | 52 | ### metric-prefix Constraints 53 | 54 | **maximum length**: the maximum number of characters for this string is: `100` 55 | 56 | **pattern**: the string must match the following regular expression: 57 | 58 | ```regexp 59 | ^[A-Za-z]+[A-Za-z0-9_\.]*\.$ 60 | ``` 61 | 62 | [try pattern](https://regexr.com/?expression=%5E%5BA-Za-z%5D%2B%5BA-Za-z0-9_%5C.%5D*%5C.%24 "try regular expression with regexr.com") 63 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-deploymentconfig.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `object` ([DeploymentConfig](definitions-definitions-deploymentconfig.md)) 4 | 5 | ## additionalProperties Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # additionalProperties Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :------------------ | :------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------- | 13 | | [relayer](#relayer) | `object` | Required | cannot be null | [Definitions](definitions-definitions-relayer.md "#/definitions/deploymentConfig/properties/relayer") | 14 | 15 | ## relayer 16 | 17 | 18 | 19 | `relayer` 20 | 21 | * is required 22 | 23 | * Type: `object` ([Relayer](definitions-definitions-relayer.md)) 24 | 25 | * cannot be null 26 | 27 | * defined in: [Definitions](definitions-definitions-relayer.md "#/definitions/deploymentConfig/properties/relayer") 28 | 29 | ### relayer Type 30 | 31 | `object` ([Relayer](definitions-definitions-relayer.md)) 32 | 33 | ### relayer Constraints 34 | 35 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 36 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-emailconfig-properties-emails-items.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` 4 | 5 | ## items Constraints 6 | 7 | **email**: the string must be an email address, according to [RFC 5322, section 3.4.1](https://tools.ietf.org/html/rfc5322 "check the specification") 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-emailconfig-properties-emails.md: -------------------------------------------------------------------------------- 1 | ## emails Type 2 | 3 | `string[]` 4 | 5 | ## emails Default Value 6 | 7 | The default value is: 8 | 9 | ```json 10 | [] 11 | ``` 12 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-emailconfig.md: -------------------------------------------------------------------------------- 1 | ## 0 Type 2 | 3 | `object` ([EmailConfig](definitions-definitions-emailconfig.md)) 4 | 5 | ## 0 Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # 0 Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :---------------- | :------ | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------- | 13 | | [emails](#emails) | `array` | Required | cannot be null | [Definitions](definitions-definitions-emailconfig-properties-emails.md "#/definitions/emailConfig/properties/emails") | 14 | 15 | ## emails 16 | 17 | 18 | 19 | `emails` 20 | 21 | * is required 22 | 23 | * Type: `string[]` 24 | 25 | * cannot be null 26 | 27 | * defined in: [Definitions](definitions-definitions-emailconfig-properties-emails.md "#/definitions/emailConfig/properties/emails") 28 | 29 | ### emails Type 30 | 31 | `string[]` 32 | 33 | ### emails Default Value 34 | 35 | The default value is: 36 | 37 | ```json 38 | [] 39 | ``` 40 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-anyof-0.md: -------------------------------------------------------------------------------- 1 | ## 0 Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-anyof-1.md: -------------------------------------------------------------------------------- 1 | ## 1 Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-addresses.md: -------------------------------------------------------------------------------- 1 | ## addresses Type 2 | 3 | `string[]` ([Address](definitions-definitions-address.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-agentids-items.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-agentids.md: -------------------------------------------------------------------------------- 1 | ## agent-ids Type 2 | 3 | `string[]` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-alertthreshold-properties-amount.md: -------------------------------------------------------------------------------- 1 | ## amount Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-alertthreshold-properties-window-seconds.md: -------------------------------------------------------------------------------- 1 | ## window-seconds Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-alertthreshold.md: -------------------------------------------------------------------------------- 1 | ## alert-threshold Type 2 | 3 | `object` ([AlertThreshold](definitions-definitions-fortasentinel-properties-alertthreshold.md)) 4 | 5 | # alert-threshold Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------------------- | :-------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | 9 | | [amount](#amount) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-alertthreshold-properties-amount.md "#/definitions/fortaSentinel/properties/alert-threshold/properties/amount") | 10 | | [window-seconds](#window-seconds) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-alertthreshold-properties-window-seconds.md "#/definitions/fortaSentinel/properties/alert-threshold/properties/window-seconds") | 11 | 12 | ## amount 13 | 14 | 15 | 16 | `amount` 17 | 18 | * is optional 19 | 20 | * Type: `integer` 21 | 22 | * cannot be null 23 | 24 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-alertthreshold-properties-amount.md "#/definitions/fortaSentinel/properties/alert-threshold/properties/amount") 25 | 26 | ### amount Type 27 | 28 | `integer` 29 | 30 | ## window-seconds 31 | 32 | 33 | 34 | `window-seconds` 35 | 36 | * is optional 37 | 38 | * Type: `integer` 39 | 40 | * cannot be null 41 | 42 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-alertthreshold-properties-window-seconds.md "#/definitions/fortaSentinel/properties/alert-threshold/properties/window-seconds") 43 | 44 | ### window-seconds Type 45 | 46 | `integer` 47 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-conditions-properties-alertids-items.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-conditions-properties-alertids.md: -------------------------------------------------------------------------------- 1 | ## alert-ids Type 2 | 3 | `string[]` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-conditions-properties-min-scanner-count.md: -------------------------------------------------------------------------------- 1 | ## min-scanner-count Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-conditions-properties-severity.md: -------------------------------------------------------------------------------- 1 | ## severity Type 2 | 3 | `integer` 4 | 5 | ## severity Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :---- | :---------- | 11 | | `0` | | 12 | | `1` | | 13 | | `2` | | 14 | | `3` | | 15 | | `4` | | 16 | | `5` | | 17 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-conditions.md: -------------------------------------------------------------------------------- 1 | ## conditions Type 2 | 3 | `object` ([Conditions](definitions-definitions-fortasentinel-properties-conditions.md)) 4 | 5 | # conditions Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------------------------- | :-------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [min-scanner-count](#min-scanner-count) | `integer` | Required | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-conditions-properties-min-scanner-count.md "#/definitions/fortaSentinel/properties/conditions/properties/min-scanner-count") | 10 | | [severity](#severity) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-conditions-properties-severity.md "#/definitions/fortaSentinel/properties/conditions/properties/severity") | 11 | | [alert-ids](#alert-ids) | `array` | Optional | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-conditions-properties-alertids.md "#/definitions/fortaSentinel/properties/conditions/properties/alert-ids") | 12 | 13 | ## min-scanner-count 14 | 15 | 16 | 17 | `min-scanner-count` 18 | 19 | * is required 20 | 21 | * Type: `integer` 22 | 23 | * cannot be null 24 | 25 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-conditions-properties-min-scanner-count.md "#/definitions/fortaSentinel/properties/conditions/properties/min-scanner-count") 26 | 27 | ### min-scanner-count Type 28 | 29 | `integer` 30 | 31 | ## severity 32 | 33 | 34 | 35 | `severity` 36 | 37 | * is optional 38 | 39 | * Type: `integer` 40 | 41 | * cannot be null 42 | 43 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-conditions-properties-severity.md "#/definitions/fortaSentinel/properties/conditions/properties/severity") 44 | 45 | ### severity Type 46 | 47 | `integer` 48 | 49 | ### severity Constraints 50 | 51 | **enum**: the value of this property must be equal to one of the following values: 52 | 53 | | Value | Explanation | 54 | | :---- | :---------- | 55 | | `0` | | 56 | | `1` | | 57 | | `2` | | 58 | | `3` | | 59 | | `4` | | 60 | | `5` | | 61 | 62 | ## alert-ids 63 | 64 | 65 | 66 | `alert-ids` 67 | 68 | * is optional 69 | 70 | * Type: `string[]` 71 | 72 | * cannot be null 73 | 74 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-conditions-properties-alertids.md "#/definitions/fortaSentinel/properties/conditions/properties/alert-ids") 75 | 76 | ### alert-ids Type 77 | 78 | `string[]` 79 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-forta-node-id.md: -------------------------------------------------------------------------------- 1 | ## forta-node-id Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-name.md: -------------------------------------------------------------------------------- 1 | ## name Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-notifyconfig-properties-channels.md: -------------------------------------------------------------------------------- 1 | ## channels Type 2 | 3 | `object[]` ([Notification](definitions-definitions-notification.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-notifyconfig-properties-message.md: -------------------------------------------------------------------------------- 1 | ## message Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-notifyconfig-properties-timeout.md: -------------------------------------------------------------------------------- 1 | ## timeout Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-notifyconfig.md: -------------------------------------------------------------------------------- 1 | ## notify-config Type 2 | 3 | `object` ([NotifyConfig](definitions-definitions-fortasentinel-properties-notifyconfig.md)) 4 | 5 | # notify-config Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :-------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [timeout](#timeout) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-notifyconfig-properties-timeout.md "#/definitions/fortaSentinel/properties/notify-config/properties/timeout") | 10 | | [message](#message) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-notifyconfig-properties-message.md "#/definitions/fortaSentinel/properties/notify-config/properties/message") | 11 | | [category](#category) | `object` | Optional | cannot be null | [Definitions](definitions-definitions-category.md "#/definitions/fortaSentinel/properties/notify-config/properties/category") | 12 | | [channels](#channels) | `array` | Required | cannot be null | [Definitions](definitions-definitions-fortasentinel-properties-notifyconfig-properties-channels.md "#/definitions/fortaSentinel/properties/notify-config/properties/channels") | 13 | 14 | ## timeout 15 | 16 | 17 | 18 | `timeout` 19 | 20 | * is optional 21 | 22 | * Type: `integer` 23 | 24 | * cannot be null 25 | 26 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-notifyconfig-properties-timeout.md "#/definitions/fortaSentinel/properties/notify-config/properties/timeout") 27 | 28 | ### timeout Type 29 | 30 | `integer` 31 | 32 | ## message 33 | 34 | 35 | 36 | `message` 37 | 38 | * is optional 39 | 40 | * Type: `string` 41 | 42 | * cannot be null 43 | 44 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-notifyconfig-properties-message.md "#/definitions/fortaSentinel/properties/notify-config/properties/message") 45 | 46 | ### message Type 47 | 48 | `string` 49 | 50 | ## category 51 | 52 | 53 | 54 | `category` 55 | 56 | * is optional 57 | 58 | * Type: `object` ([Category](definitions-definitions-category.md)) 59 | 60 | * cannot be null 61 | 62 | * defined in: [Definitions](definitions-definitions-category.md "#/definitions/fortaSentinel/properties/notify-config/properties/category") 63 | 64 | ### category Type 65 | 66 | `object` ([Category](definitions-definitions-category.md)) 67 | 68 | ### category Constraints 69 | 70 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 71 | 72 | ## channels 73 | 74 | 75 | 76 | `channels` 77 | 78 | * is required 79 | 80 | * Type: `object[]` ([Notification](definitions-definitions-notification.md)) 81 | 82 | * cannot be null 83 | 84 | * defined in: [Definitions](definitions-definitions-fortasentinel-properties-notifyconfig-properties-channels.md "#/definitions/fortaSentinel/properties/notify-config/properties/channels") 85 | 86 | ### channels Type 87 | 88 | `object[]` ([Notification](definitions-definitions-notification.md)) 89 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-paused.md: -------------------------------------------------------------------------------- 1 | ## paused Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-fortasentinel-properties-type.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | `string` 4 | 5 | ## type Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :-------- | :---------- | 11 | | `"FORTA"` | | 12 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-network.md: -------------------------------------------------------------------------------- 1 | ## network Type 2 | 3 | `string` ([Network](definitions-definitions-network.md)) 4 | 5 | ## network Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :------------------------ | :---------- | 11 | | `"alfajores"` | | 12 | | `"amoy"` | | 13 | | `"arbitrum"` | | 14 | | `"arbitrum-nova"` | | 15 | | `"arbitrum-rinkeby"` | | 16 | | `"aurora"` | | 17 | | `"auroratest"` | | 18 | | `"avalanche"` | | 19 | | `"base"` | | 20 | | `"bsc"` | | 21 | | `"bsctest"` | | 22 | | `"celo"` | | 23 | | `"fantom"` | | 24 | | `"fantomtest"` | | 25 | | `"fuji"` | | 26 | | `"fuse"` | | 27 | | `"harmony-s0"` | | 28 | | `"harmony-test-s0"` | | 29 | | `"hedera"` | | 30 | | `"hederatest"` | | 31 | | `"kovan"` | | 32 | | `"linea"` | | 33 | | `"linea-goerli"` | | 34 | | `"mainnet"` | | 35 | | `"matic"` | | 36 | | `"moonbase"` | | 37 | | `"moonbeam"` | | 38 | | `"moonriver"` | | 39 | | `"mumbai"` | | 40 | | `"optimism"` | | 41 | | `"optimism-kovan"` | | 42 | | `"rinkeby"` | | 43 | | `"ropsten"` | | 44 | | `"sepolia"` | | 45 | | `"sokol"` | | 46 | | `"x-dfk-avax-chain"` | | 47 | | `"x-dfk-avax-chain-test"` | | 48 | | `"xdai"` | | 49 | | `"zksync"` | | 50 | 51 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 52 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-notification-properties-config.md: -------------------------------------------------------------------------------- 1 | ## config Type 2 | 3 | `object` ([Config](definitions-definitions-notification-properties-config.md)) 4 | 5 | one (and only one) of 6 | 7 | * [EmailConfig](definitions-definitions-emailconfig.md "check type definition") 8 | 9 | * [TelegramConfig](definitions-definitions-telegramconfig.md "check type definition") 10 | 11 | * [DatadogConfig](definitions-definitions-datadogconfig.md "check type definition") 12 | 13 | * [UrlConfig](definitions-definitions-urlconfig.md "check type definition") 14 | 15 | * [OpsgenieConfig](definitions-definitions-opsgenieconfig.md "check type definition") 16 | 17 | * [PagerDutyConfig](definitions-definitions-pagerdutyconfig.md "check type definition") 18 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-notification-properties-name.md: -------------------------------------------------------------------------------- 1 | ## name Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-notification-properties-paused.md: -------------------------------------------------------------------------------- 1 | ## paused Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-notification.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `object` ([Notification](definitions-definitions-notification.md)) 4 | 5 | ## additionalProperties Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # additionalProperties Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :---------------- | :-------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------------- | 13 | | [type](#type) | `string` | Required | cannot be null | [Definitions](definitions-definitions-notificationtype.md "#/definitions/notification/properties/type") | 14 | | [name](#name) | `string` | Required | cannot be null | [Definitions](definitions-definitions-notification-properties-name.md "#/definitions/notification/properties/name") | 15 | | [paused](#paused) | `boolean` | Required | cannot be null | [Definitions](definitions-definitions-notification-properties-paused.md "#/definitions/notification/properties/paused") | 16 | | [config](#config) | Merged | Required | cannot be null | [Definitions](definitions-definitions-notification-properties-config.md "#/definitions/notification/properties/config") | 17 | 18 | ## type 19 | 20 | 21 | 22 | `type` 23 | 24 | * is required 25 | 26 | * Type: `string` ([NotificationType](definitions-definitions-notificationtype.md)) 27 | 28 | * cannot be null 29 | 30 | * defined in: [Definitions](definitions-definitions-notificationtype.md "#/definitions/notification/properties/type") 31 | 32 | ### type Type 33 | 34 | `string` ([NotificationType](definitions-definitions-notificationtype.md)) 35 | 36 | ### type Constraints 37 | 38 | **enum**: the value of this property must be equal to one of the following values: 39 | 40 | | Value | Explanation | 41 | | :------------- | :---------- | 42 | | `"slack"` | | 43 | | `"email"` | | 44 | | `"discord"` | | 45 | | `"telegram"` | | 46 | | `"datadog"` | | 47 | | `"webhook"` | | 48 | | `"opsgenie"` | | 49 | | `"pager-duty"` | | 50 | 51 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 52 | 53 | ## name 54 | 55 | 56 | 57 | `name` 58 | 59 | * is required 60 | 61 | * Type: `string` 62 | 63 | * cannot be null 64 | 65 | * defined in: [Definitions](definitions-definitions-notification-properties-name.md "#/definitions/notification/properties/name") 66 | 67 | ### name Type 68 | 69 | `string` 70 | 71 | ## paused 72 | 73 | 74 | 75 | `paused` 76 | 77 | * is required 78 | 79 | * Type: `boolean` 80 | 81 | * cannot be null 82 | 83 | * defined in: [Definitions](definitions-definitions-notification-properties-paused.md "#/definitions/notification/properties/paused") 84 | 85 | ### paused Type 86 | 87 | `boolean` 88 | 89 | ## config 90 | 91 | 92 | 93 | `config` 94 | 95 | * is required 96 | 97 | * Type: `object` ([Config](definitions-definitions-notification-properties-config.md)) 98 | 99 | * cannot be null 100 | 101 | * defined in: [Definitions](definitions-definitions-notification-properties-config.md "#/definitions/notification/properties/config") 102 | 103 | ### config Type 104 | 105 | `object` ([Config](definitions-definitions-notification-properties-config.md)) 106 | 107 | one (and only one) of 108 | 109 | * [EmailConfig](definitions-definitions-emailconfig.md "check type definition") 110 | 111 | * [TelegramConfig](definitions-definitions-telegramconfig.md "check type definition") 112 | 113 | * [DatadogConfig](definitions-definitions-datadogconfig.md "check type definition") 114 | 115 | * [UrlConfig](definitions-definitions-urlconfig.md "check type definition") 116 | 117 | * [OpsgenieConfig](definitions-definitions-opsgenieconfig.md "check type definition") 118 | 119 | * [PagerDutyConfig](definitions-definitions-pagerdutyconfig.md "check type definition") 120 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-notificationtype.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | `string` ([NotificationType](definitions-definitions-notificationtype.md)) 4 | 5 | ## type Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :------------- | :---------- | 11 | | `"slack"` | | 12 | | `"email"` | | 13 | | `"discord"` | | 14 | | `"telegram"` | | 15 | | `"datadog"` | | 16 | | `"webhook"` | | 17 | | `"opsgenie"` | | 18 | | `"pager-duty"` | | 19 | 20 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 21 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-actions-items.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` 4 | 5 | ## items Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `50` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-actions.md: -------------------------------------------------------------------------------- 1 | ## actions Type 2 | 3 | `string[]` 4 | 5 | ## actions Constraints 6 | 7 | **maximum number of items**: the maximum number of items for this array is: `10` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-alias.md: -------------------------------------------------------------------------------- 1 | ## alias Type 2 | 3 | `string` 4 | 5 | ## alias Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `512` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-apikey.md: -------------------------------------------------------------------------------- 1 | ## apiKey Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-details-additionalproperties.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-details.md: -------------------------------------------------------------------------------- 1 | ## details Type 2 | 3 | `object` ([Details](definitions-definitions-opsgenieconfig-properties-details.md)) 4 | 5 | # details Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `string` | Optional | cannot be null | [Definitions](definitions-definitions-opsgenieconfig-properties-details-additionalproperties.md "#/definitions/opsgenieConfig/properties/details/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `string` 20 | 21 | * cannot be null 22 | 23 | * defined in: [Definitions](definitions-definitions-opsgenieconfig-properties-details-additionalproperties.md "#/definitions/opsgenieConfig/properties/details/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `string` 28 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-entity.md: -------------------------------------------------------------------------------- 1 | ## entity Type 2 | 3 | `string` 4 | 5 | ## entity Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `512` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-note.md: -------------------------------------------------------------------------------- 1 | ## note Type 2 | 3 | `string` 4 | 5 | ## note Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `25000` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-responders.md: -------------------------------------------------------------------------------- 1 | ## responders Type 2 | 3 | `object[]` ([Details](definitions-definitions-opsgenieuser.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-tags-items.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` 4 | 5 | ## items Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `50` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-tags.md: -------------------------------------------------------------------------------- 1 | ## tags Type 2 | 3 | `string[]` 4 | 5 | ## tags Constraints 6 | 7 | **maximum number of items**: the maximum number of items for this array is: `10` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties-visibleto.md: -------------------------------------------------------------------------------- 1 | ## visibleTo Type 2 | 3 | `object[]` ([Details](definitions-definitions-opsgenieuser.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieconfig-properties.md: -------------------------------------------------------------------------------- 1 | ## properties Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieinstancelocation.md: -------------------------------------------------------------------------------- 1 | ## instanceLocation Type 2 | 3 | `string` ([OpsgenieInstanceLocation](definitions-definitions-opsgenieinstancelocation.md)) 4 | 5 | ## instanceLocation Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :----- | :---------- | 11 | | `"US"` | | 12 | | `"EU"` | | 13 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieprioritylevel.md: -------------------------------------------------------------------------------- 1 | ## priority Type 2 | 3 | `string` ([OpsgeniePriorityLevel](definitions-definitions-opsgenieprioritylevel.md)) 4 | 5 | ## priority Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :----- | :---------- | 11 | | `"P1"` | | 12 | | `"P2"` | | 13 | | `"P3"` | | 14 | | `"P4"` | | 15 | | `"P5"` | | 16 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieuser-properties-fullname.md: -------------------------------------------------------------------------------- 1 | ## fullName Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieuser-properties-id.md: -------------------------------------------------------------------------------- 1 | ## id Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieuser-properties-username.md: -------------------------------------------------------------------------------- 1 | ## username Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieuser.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `object` ([Details](definitions-definitions-opsgenieuser.md)) 4 | 5 | # items Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------- | 9 | | [username](#username) | `string` | Required | cannot be null | [Definitions](definitions-definitions-opsgenieuser-properties-username.md "#/definitions/opsgenieUser/properties/username") | 10 | | [fullName](#fullname) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-opsgenieuser-properties-fullname.md "#/definitions/opsgenieUser/properties/fullName") | 11 | | [id](#id) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-opsgenieuser-properties-id.md "#/definitions/opsgenieUser/properties/id") | 12 | | [type](#type) | `string` | Required | cannot be null | [Definitions](definitions-definitions-opsgenieusertype.md "#/definitions/opsgenieUser/properties/type") | 13 | 14 | ## username 15 | 16 | 17 | 18 | `username` 19 | 20 | * is required 21 | 22 | * Type: `string` 23 | 24 | * cannot be null 25 | 26 | * defined in: [Definitions](definitions-definitions-opsgenieuser-properties-username.md "#/definitions/opsgenieUser/properties/username") 27 | 28 | ### username Type 29 | 30 | `string` 31 | 32 | ## fullName 33 | 34 | 35 | 36 | `fullName` 37 | 38 | * is optional 39 | 40 | * Type: `string` 41 | 42 | * cannot be null 43 | 44 | * defined in: [Definitions](definitions-definitions-opsgenieuser-properties-fullname.md "#/definitions/opsgenieUser/properties/fullName") 45 | 46 | ### fullName Type 47 | 48 | `string` 49 | 50 | ## id 51 | 52 | 53 | 54 | `id` 55 | 56 | * is optional 57 | 58 | * Type: `string` 59 | 60 | * cannot be null 61 | 62 | * defined in: [Definitions](definitions-definitions-opsgenieuser-properties-id.md "#/definitions/opsgenieUser/properties/id") 63 | 64 | ### id Type 65 | 66 | `string` 67 | 68 | ## type 69 | 70 | 71 | 72 | `type` 73 | 74 | * is required 75 | 76 | * Type: `string` ([opsgenieUserType](definitions-definitions-opsgenieusertype.md)) 77 | 78 | * cannot be null 79 | 80 | * defined in: [Definitions](definitions-definitions-opsgenieusertype.md "#/definitions/opsgenieUser/properties/type") 81 | 82 | ### type Type 83 | 84 | `string` ([opsgenieUserType](definitions-definitions-opsgenieusertype.md)) 85 | 86 | ### type Constraints 87 | 88 | **enum**: the value of this property must be equal to one of the following values: 89 | 90 | | Value | Explanation | 91 | | :------------- | :---------- | 92 | | `"team"` | | 93 | | `"user"` | | 94 | | `"escalation"` | | 95 | | `"schedule"` | | 96 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-opsgenieusertype.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | `string` ([opsgenieUserType](definitions-definitions-opsgenieusertype.md)) 4 | 5 | ## type Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :------------- | :---------- | 11 | | `"team"` | | 12 | | `"user"` | | 13 | | `"escalation"` | | 14 | | `"schedule"` | | 15 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-if-properties-eventtype.md: -------------------------------------------------------------------------------- 1 | ## eventType Type 2 | 3 | unknown 4 | 5 | ## eventType Constraints 6 | 7 | **constant**: the value of this property must be equal to: 8 | 9 | ```json 10 | "alert" 11 | ``` 12 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-if-properties.md: -------------------------------------------------------------------------------- 1 | ## properties Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-if.md: -------------------------------------------------------------------------------- 1 | ## if Type 2 | 3 | unknown 4 | 5 | # if Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :---------------------- | :------------ | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [eventType](#eventtype) | Not specified | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-if-properties-eventtype.md "#/definitions/pagerDutyConfig/if/properties/eventType") | 10 | 11 | ## eventType 12 | 13 | 14 | 15 | `eventType` 16 | 17 | * is optional 18 | 19 | * Type: unknown 20 | 21 | * cannot be null 22 | 23 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-if-properties-eventtype.md "#/definitions/pagerDutyConfig/if/properties/eventType") 24 | 25 | ### eventType Type 26 | 27 | unknown 28 | 29 | ### eventType Constraints 30 | 31 | **constant**: the value of this property must be equal to: 32 | 33 | ```json 34 | "alert" 35 | ``` 36 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-class.md: -------------------------------------------------------------------------------- 1 | ## class Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-component.md: -------------------------------------------------------------------------------- 1 | ## component Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-customdetails-additionalproperties.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-customdetails.md: -------------------------------------------------------------------------------- 1 | ## customDetails Type 2 | 3 | `object` ([Details](definitions-definitions-pagerdutyconfig-properties-customdetails.md)) 4 | 5 | # customDetails Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `string` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-customdetails-additionalproperties.md "#/definitions/pagerDutyConfig/properties/customDetails/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `string` 20 | 21 | * cannot be null 22 | 23 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-customdetails-additionalproperties.md "#/definitions/pagerDutyConfig/properties/customDetails/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `string` 28 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-dedupkey.md: -------------------------------------------------------------------------------- 1 | ## dedupKey Type 2 | 3 | `string` 4 | 5 | ## dedupKey Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `255` 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-group.md: -------------------------------------------------------------------------------- 1 | ## group Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-routingkey.md: -------------------------------------------------------------------------------- 1 | ## routingKey Type 2 | 3 | `string` 4 | 5 | ## routingKey Constraints 6 | 7 | **maximum length**: the maximum number of characters for this string is: `32` 8 | 9 | **minimum length**: the minimum number of characters for this string is: `32` 10 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties-token.md: -------------------------------------------------------------------------------- 1 | ## token Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-properties.md: -------------------------------------------------------------------------------- 1 | ## properties Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig-then.md: -------------------------------------------------------------------------------- 1 | ## then Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyconfig.md: -------------------------------------------------------------------------------- 1 | ## 5 Type 2 | 3 | unknown ([PagerDutyConfig](definitions-definitions-pagerdutyconfig.md)) 4 | 5 | ## 5 Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # 5 Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :------------------------------ | :------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------- | 13 | | [token](#token) | `string` | Required | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-token.md "#/definitions/pagerDutyConfig/properties/token") | 14 | | [eventType](#eventtype) | `string` | Required | cannot be null | [Definitions](definitions-definitions-pagerdutyeventtype.md "#/definitions/pagerDutyConfig/properties/eventType") | 15 | | [routingKey](#routingkey) | `string` | Required | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-routingkey.md "#/definitions/pagerDutyConfig/properties/routingKey") | 16 | | [eventAction](#eventaction) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyeventaction.md "#/definitions/pagerDutyConfig/properties/eventAction") | 17 | | [dedupKey](#dedupkey) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-dedupkey.md "#/definitions/pagerDutyConfig/properties/dedupKey") | 18 | | [severity](#severity) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyseverity.md "#/definitions/pagerDutyConfig/properties/severity") | 19 | | [component](#component) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-component.md "#/definitions/pagerDutyConfig/properties/component") | 20 | | [group](#group) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-group.md "#/definitions/pagerDutyConfig/properties/group") | 21 | | [class](#class) | `string` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-class.md "#/definitions/pagerDutyConfig/properties/class") | 22 | | [customDetails](#customdetails) | `object` | Optional | cannot be null | [Definitions](definitions-definitions-pagerdutyconfig-properties-customdetails.md "#/definitions/pagerDutyConfig/properties/customDetails") | 23 | 24 | ## token 25 | 26 | 27 | 28 | `token` 29 | 30 | * is required 31 | 32 | * Type: `string` 33 | 34 | * cannot be null 35 | 36 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-token.md "#/definitions/pagerDutyConfig/properties/token") 37 | 38 | ### token Type 39 | 40 | `string` 41 | 42 | ## eventType 43 | 44 | 45 | 46 | `eventType` 47 | 48 | * is required 49 | 50 | * Type: `string` ([PagerDutyEventType](definitions-definitions-pagerdutyeventtype.md)) 51 | 52 | * cannot be null 53 | 54 | * defined in: [Definitions](definitions-definitions-pagerdutyeventtype.md "#/definitions/pagerDutyConfig/properties/eventType") 55 | 56 | ### eventType Type 57 | 58 | `string` ([PagerDutyEventType](definitions-definitions-pagerdutyeventtype.md)) 59 | 60 | ### eventType Constraints 61 | 62 | **enum**: the value of this property must be equal to one of the following values: 63 | 64 | | Value | Explanation | 65 | | :--------- | :---------- | 66 | | `"change"` | | 67 | | `"alert"` | | 68 | 69 | ## routingKey 70 | 71 | 72 | 73 | `routingKey` 74 | 75 | * is required 76 | 77 | * Type: `string` 78 | 79 | * cannot be null 80 | 81 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-routingkey.md "#/definitions/pagerDutyConfig/properties/routingKey") 82 | 83 | ### routingKey Type 84 | 85 | `string` 86 | 87 | ### routingKey Constraints 88 | 89 | **maximum length**: the maximum number of characters for this string is: `32` 90 | 91 | **minimum length**: the minimum number of characters for this string is: `32` 92 | 93 | ## eventAction 94 | 95 | 96 | 97 | `eventAction` 98 | 99 | * is optional 100 | 101 | * Type: `string` ([PagerDutyEventAction](definitions-definitions-pagerdutyeventaction.md)) 102 | 103 | * cannot be null 104 | 105 | * defined in: [Definitions](definitions-definitions-pagerdutyeventaction.md "#/definitions/pagerDutyConfig/properties/eventAction") 106 | 107 | ### eventAction Type 108 | 109 | `string` ([PagerDutyEventAction](definitions-definitions-pagerdutyeventaction.md)) 110 | 111 | ### eventAction Constraints 112 | 113 | **enum**: the value of this property must be equal to one of the following values: 114 | 115 | | Value | Explanation | 116 | | :-------------- | :---------- | 117 | | `"trigger"` | | 118 | | `"acknowledge"` | | 119 | | `"resolve"` | | 120 | 121 | ## dedupKey 122 | 123 | 124 | 125 | `dedupKey` 126 | 127 | * is optional 128 | 129 | * Type: `string` 130 | 131 | * cannot be null 132 | 133 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-dedupkey.md "#/definitions/pagerDutyConfig/properties/dedupKey") 134 | 135 | ### dedupKey Type 136 | 137 | `string` 138 | 139 | ### dedupKey Constraints 140 | 141 | **maximum length**: the maximum number of characters for this string is: `255` 142 | 143 | ## severity 144 | 145 | 146 | 147 | `severity` 148 | 149 | * is optional 150 | 151 | * Type: `string` ([PagerDutySeverity](definitions-definitions-pagerdutyseverity.md)) 152 | 153 | * cannot be null 154 | 155 | * defined in: [Definitions](definitions-definitions-pagerdutyseverity.md "#/definitions/pagerDutyConfig/properties/severity") 156 | 157 | ### severity Type 158 | 159 | `string` ([PagerDutySeverity](definitions-definitions-pagerdutyseverity.md)) 160 | 161 | ### severity Constraints 162 | 163 | **enum**: the value of this property must be equal to one of the following values: 164 | 165 | | Value | Explanation | 166 | | :----------- | :---------- | 167 | | `"critical"` | | 168 | | `"error"` | | 169 | | `"warning"` | | 170 | | `"info"` | | 171 | 172 | ## component 173 | 174 | 175 | 176 | `component` 177 | 178 | * is optional 179 | 180 | * Type: `string` 181 | 182 | * cannot be null 183 | 184 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-component.md "#/definitions/pagerDutyConfig/properties/component") 185 | 186 | ### component Type 187 | 188 | `string` 189 | 190 | ## group 191 | 192 | 193 | 194 | `group` 195 | 196 | * is optional 197 | 198 | * Type: `string` 199 | 200 | * cannot be null 201 | 202 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-group.md "#/definitions/pagerDutyConfig/properties/group") 203 | 204 | ### group Type 205 | 206 | `string` 207 | 208 | ## class 209 | 210 | 211 | 212 | `class` 213 | 214 | * is optional 215 | 216 | * Type: `string` 217 | 218 | * cannot be null 219 | 220 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-class.md "#/definitions/pagerDutyConfig/properties/class") 221 | 222 | ### class Type 223 | 224 | `string` 225 | 226 | ## customDetails 227 | 228 | 229 | 230 | `customDetails` 231 | 232 | * is optional 233 | 234 | * Type: `object` ([Details](definitions-definitions-pagerdutyconfig-properties-customdetails.md)) 235 | 236 | * cannot be null 237 | 238 | * defined in: [Definitions](definitions-definitions-pagerdutyconfig-properties-customdetails.md "#/definitions/pagerDutyConfig/properties/customDetails") 239 | 240 | ### customDetails Type 241 | 242 | `object` ([Details](definitions-definitions-pagerdutyconfig-properties-customdetails.md)) 243 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyeventaction.md: -------------------------------------------------------------------------------- 1 | ## eventAction Type 2 | 3 | `string` ([PagerDutyEventAction](definitions-definitions-pagerdutyeventaction.md)) 4 | 5 | ## eventAction Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :-------------- | :---------- | 11 | | `"trigger"` | | 12 | | `"acknowledge"` | | 13 | | `"resolve"` | | 14 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyeventtype.md: -------------------------------------------------------------------------------- 1 | ## eventType Type 2 | 3 | `string` ([PagerDutyEventType](definitions-definitions-pagerdutyeventtype.md)) 4 | 5 | ## eventType Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :--------- | :---------- | 11 | | `"change"` | | 12 | | `"alert"` | | 13 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-pagerdutyseverity.md: -------------------------------------------------------------------------------- 1 | ## severity Type 2 | 3 | `string` ([PagerDutySeverity](definitions-definitions-pagerdutyseverity.md)) 4 | 5 | ## severity Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :----------- | :---------- | 11 | | `"critical"` | | 12 | | `"error"` | | 13 | | `"warning"` | | 14 | | `"info"` | | 15 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-policy-properties-eip1559-pricing.md: -------------------------------------------------------------------------------- 1 | ## eip1559-pricing Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-policy-properties-gas-price-cap.md: -------------------------------------------------------------------------------- 1 | ## gas-price-cap Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-policy-properties-private-transactions.md: -------------------------------------------------------------------------------- 1 | ## private-transactions Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-policy-properties-whitelistreceivers-items.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-policy-properties-whitelistreceivers.md: -------------------------------------------------------------------------------- 1 | ## whitelist-receivers Type 2 | 3 | `string[]` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-policy.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `object` ([Policy](definitions-definitions-policy.md)) 4 | 5 | ## additionalProperties Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # additionalProperties Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :-------------------------------------------- | :-------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------------------- | 13 | | [gas-price-cap](#gas-price-cap) | `integer` | Optional | cannot be null | [Definitions](definitions-definitions-policy-properties-gas-price-cap.md "#/definitions/policy/properties/gas-price-cap") | 14 | | [whitelist-receivers](#whitelist-receivers) | `array` | Optional | cannot be null | [Definitions](definitions-definitions-policy-properties-whitelistreceivers.md "#/definitions/policy/properties/whitelist-receivers") | 15 | | [eip1559-pricing](#eip1559-pricing) | `boolean` | Optional | cannot be null | [Definitions](definitions-definitions-policy-properties-eip1559-pricing.md "#/definitions/policy/properties/eip1559-pricing") | 16 | | [private-transactions](#private-transactions) | `boolean` | Optional | cannot be null | [Definitions](definitions-definitions-policy-properties-private-transactions.md "#/definitions/policy/properties/private-transactions") | 17 | 18 | ## gas-price-cap 19 | 20 | 21 | 22 | `gas-price-cap` 23 | 24 | * is optional 25 | 26 | * Type: `integer` 27 | 28 | * cannot be null 29 | 30 | * defined in: [Definitions](definitions-definitions-policy-properties-gas-price-cap.md "#/definitions/policy/properties/gas-price-cap") 31 | 32 | ### gas-price-cap Type 33 | 34 | `integer` 35 | 36 | ## whitelist-receivers 37 | 38 | 39 | 40 | `whitelist-receivers` 41 | 42 | * is optional 43 | 44 | * Type: `string[]` 45 | 46 | * cannot be null 47 | 48 | * defined in: [Definitions](definitions-definitions-policy-properties-whitelistreceivers.md "#/definitions/policy/properties/whitelist-receivers") 49 | 50 | ### whitelist-receivers Type 51 | 52 | `string[]` 53 | 54 | ## eip1559-pricing 55 | 56 | 57 | 58 | `eip1559-pricing` 59 | 60 | * is optional 61 | 62 | * Type: `boolean` 63 | 64 | * cannot be null 65 | 66 | * defined in: [Definitions](definitions-definitions-policy-properties-eip1559-pricing.md "#/definitions/policy/properties/eip1559-pricing") 67 | 68 | ### eip1559-pricing Type 69 | 70 | `boolean` 71 | 72 | ## private-transactions 73 | 74 | 75 | 76 | `private-transactions` 77 | 78 | * is optional 79 | 80 | * Type: `boolean` 81 | 82 | * cannot be null 83 | 84 | * defined in: [Definitions](definitions-definitions-policy-properties-private-transactions.md "#/definitions/policy/properties/private-transactions") 85 | 86 | ### private-transactions Type 87 | 88 | `boolean` 89 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-relayer-properties-addressfromrelayer.md: -------------------------------------------------------------------------------- 1 | ## address-from-relayer Type 2 | 3 | `object` ([AddressFromRelayer](definitions-definitions-relayer-properties-addressfromrelayer.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-relayer-properties-min-balance.md: -------------------------------------------------------------------------------- 1 | ## min-balance Type 2 | 3 | `integer` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-relayer-properties-name.md: -------------------------------------------------------------------------------- 1 | ## name Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-relayer-properties-relayerapikeys-items.md: -------------------------------------------------------------------------------- 1 | ## items Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-relayer-properties-relayerapikeys.md: -------------------------------------------------------------------------------- 1 | ## api-keys Type 2 | 3 | `string[]` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-relayer.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `object` ([Relayer](definitions-definitions-relayer.md)) 4 | 5 | ## additionalProperties Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # additionalProperties Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :-------------------------------------------- | :-------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------------------- | 13 | | [name](#name) | `string` | Required | cannot be null | [Definitions](definitions-definitions-relayer-properties-name.md "#/definitions/relayer/properties/name") | 14 | | [network](#network) | `string` | Required | cannot be null | [Definitions](definitions-definitions-network.md "#/definitions/relayer/properties/network") | 15 | | [min-balance](#min-balance) | `integer` | Required | cannot be null | [Definitions](definitions-definitions-relayer-properties-min-balance.md "#/definitions/relayer/properties/min-balance") | 16 | | [address-from-relayer](#address-from-relayer) | `object` | Optional | cannot be null | [Definitions](definitions-definitions-relayer-properties-addressfromrelayer.md "#/definitions/relayer/properties/address-from-relayer") | 17 | | [policy](#policy) | `object` | Optional | cannot be null | [Definitions](definitions-definitions-policy.md "#/definitions/relayer/properties/policy") | 18 | | [api-keys](#api-keys) | `array` | Optional | cannot be null | [Definitions](definitions-definitions-relayer-properties-relayerapikeys.md "#/definitions/relayer/properties/api-keys") | 19 | 20 | ## name 21 | 22 | 23 | 24 | `name` 25 | 26 | * is required 27 | 28 | * Type: `string` 29 | 30 | * cannot be null 31 | 32 | * defined in: [Definitions](definitions-definitions-relayer-properties-name.md "#/definitions/relayer/properties/name") 33 | 34 | ### name Type 35 | 36 | `string` 37 | 38 | ## network 39 | 40 | 41 | 42 | `network` 43 | 44 | * is required 45 | 46 | * Type: `string` ([Network](definitions-definitions-network.md)) 47 | 48 | * cannot be null 49 | 50 | * defined in: [Definitions](definitions-definitions-network.md "#/definitions/relayer/properties/network") 51 | 52 | ### network Type 53 | 54 | `string` ([Network](definitions-definitions-network.md)) 55 | 56 | ### network Constraints 57 | 58 | **enum**: the value of this property must be equal to one of the following values: 59 | 60 | | Value | Explanation | 61 | | :------------------------ | :---------- | 62 | | `"alfajores"` | | 63 | | `"amoy"` | | 64 | | `"arbitrum"` | | 65 | | `"arbitrum-nova"` | | 66 | | `"arbitrum-rinkeby"` | | 67 | | `"aurora"` | | 68 | | `"auroratest"` | | 69 | | `"avalanche"` | | 70 | | `"base"` | | 71 | | `"bsc"` | | 72 | | `"bsctest"` | | 73 | | `"celo"` | | 74 | | `"fantom"` | | 75 | | `"fantomtest"` | | 76 | | `"fuji"` | | 77 | | `"fuse"` | | 78 | | `"harmony-s0"` | | 79 | | `"harmony-test-s0"` | | 80 | | `"hedera"` | | 81 | | `"hederatest"` | | 82 | | `"kovan"` | | 83 | | `"linea"` | | 84 | | `"linea-goerli"` | | 85 | | `"mainnet"` | | 86 | | `"matic"` | | 87 | | `"moonbase"` | | 88 | | `"moonbeam"` | | 89 | | `"moonriver"` | | 90 | | `"mumbai"` | | 91 | | `"optimism"` | | 92 | | `"optimism-kovan"` | | 93 | | `"rinkeby"` | | 94 | | `"ropsten"` | | 95 | | `"sepolia"` | | 96 | | `"sokol"` | | 97 | | `"x-dfk-avax-chain"` | | 98 | | `"x-dfk-avax-chain-test"` | | 99 | | `"xdai"` | | 100 | | `"zksync"` | | 101 | 102 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 103 | 104 | ## min-balance 105 | 106 | 107 | 108 | `min-balance` 109 | 110 | * is required 111 | 112 | * Type: `integer` 113 | 114 | * cannot be null 115 | 116 | * defined in: [Definitions](definitions-definitions-relayer-properties-min-balance.md "#/definitions/relayer/properties/min-balance") 117 | 118 | ### min-balance Type 119 | 120 | `integer` 121 | 122 | ## address-from-relayer 123 | 124 | 125 | 126 | `address-from-relayer` 127 | 128 | * is optional 129 | 130 | * Type: `object` ([AddressFromRelayer](definitions-definitions-relayer-properties-addressfromrelayer.md)) 131 | 132 | * cannot be null 133 | 134 | * defined in: [Definitions](definitions-definitions-relayer-properties-addressfromrelayer.md "#/definitions/relayer/properties/address-from-relayer") 135 | 136 | ### address-from-relayer Type 137 | 138 | `object` ([AddressFromRelayer](definitions-definitions-relayer-properties-addressfromrelayer.md)) 139 | 140 | ## policy 141 | 142 | 143 | 144 | `policy` 145 | 146 | * is optional 147 | 148 | * Type: `object` ([Policy](definitions-definitions-policy.md)) 149 | 150 | * cannot be null 151 | 152 | * defined in: [Definitions](definitions-definitions-policy.md "#/definitions/relayer/properties/policy") 153 | 154 | ### policy Type 155 | 156 | `object` ([Policy](definitions-definitions-policy.md)) 157 | 158 | ### policy Constraints 159 | 160 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 161 | 162 | ## api-keys 163 | 164 | 165 | 166 | `api-keys` 167 | 168 | * is optional 169 | 170 | * Type: `string[]` 171 | 172 | * cannot be null 173 | 174 | * defined in: [Definitions](definitions-definitions-relayer-properties-relayerapikeys.md "#/definitions/relayer/properties/api-keys") 175 | 176 | ### api-keys Type 177 | 178 | `string[]` 179 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-riskcategory.md: -------------------------------------------------------------------------------- 1 | ## risk-category Type 2 | 3 | `string` ([RiskCategory](definitions-definitions-riskcategory.md)) 4 | 5 | ## risk-category Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :----------------- | :---------- | 11 | | `"NONE"` | | 12 | | `"GOVERNANCE"` | | 13 | | `"ACCESS-CONTROL"` | | 14 | | `"SUSPICIOUS"` | | 15 | | `"FINANCIAL"` | | 16 | | `"TECHNICAL"` | | 17 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-sentinel.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `object` ([Sentinel](definitions-definitions-sentinel.md)) 4 | 5 | one (and only one) of 6 | 7 | * [BlockSentinel](definitions-definitions-blocksentinel.md "check type definition") 8 | 9 | * any of 10 | 11 | * [Untitled type in Definitions](definitions-definitions-fortasentinel-anyof-0.md "check type definition") 12 | 13 | * [Untitled type in Definitions](definitions-definitions-fortasentinel-anyof-1.md "check type definition") 14 | 15 | ## additionalProperties Constraints 16 | 17 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 18 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-telegramconfig-properties-bot-token.md: -------------------------------------------------------------------------------- 1 | ## bot-token Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-telegramconfig-properties-chat-id.md: -------------------------------------------------------------------------------- 1 | ## chat-id Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-telegramconfig.md: -------------------------------------------------------------------------------- 1 | ## 1 Type 2 | 3 | `object` ([TelegramConfig](definitions-definitions-telegramconfig.md)) 4 | 5 | ## 1 Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # 1 Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :---------------------- | :------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------------- | 13 | | [bot-token](#bot-token) | `string` | Required | cannot be null | [Definitions](definitions-definitions-telegramconfig-properties-bot-token.md "#/definitions/telegramBotConfig/properties/bot-token") | 14 | | [chat-id](#chat-id) | `string` | Required | cannot be null | [Definitions](definitions-definitions-telegramconfig-properties-chat-id.md "#/definitions/telegramBotConfig/properties/chat-id") | 15 | 16 | ## bot-token 17 | 18 | 19 | 20 | `bot-token` 21 | 22 | * is required 23 | 24 | * Type: `string` 25 | 26 | * cannot be null 27 | 28 | * defined in: [Definitions](definitions-definitions-telegramconfig-properties-bot-token.md "#/definitions/telegramBotConfig/properties/bot-token") 29 | 30 | ### bot-token Type 31 | 32 | `string` 33 | 34 | ## chat-id 35 | 36 | 37 | 38 | `chat-id` 39 | 40 | * is required 41 | 42 | * Type: `string` 43 | 44 | * cannot be null 45 | 46 | * defined in: [Definitions](definitions-definitions-telegramconfig-properties-chat-id.md "#/definitions/telegramBotConfig/properties/chat-id") 47 | 48 | ### chat-id Type 49 | 50 | `string` 51 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-urlconfig-properties-url.md: -------------------------------------------------------------------------------- 1 | ## url Type 2 | 3 | `string` 4 | 5 | ## url Constraints 6 | 7 | **URI**: the string must be a URI, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions-urlconfig.md: -------------------------------------------------------------------------------- 1 | ## 3 Type 2 | 3 | `object` ([UrlConfig](definitions-definitions-urlconfig.md)) 4 | 5 | ## 3 Constraints 6 | 7 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 8 | 9 | # 3 Properties 10 | 11 | | Property | Type | Required | Nullable | Defined by | 12 | | :---------- | :------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------- | 13 | | [url](#url) | `string` | Required | cannot be null | [Definitions](definitions-definitions-urlconfig-properties-url.md "#/definitions/urlConfig/properties/url") | 14 | 15 | ## url 16 | 17 | 18 | 19 | `url` 20 | 21 | * is required 22 | 23 | * Type: `string` 24 | 25 | * cannot be null 26 | 27 | * defined in: [Definitions](definitions-definitions-urlconfig-properties-url.md "#/definitions/urlConfig/properties/url") 28 | 29 | ### url Type 30 | 31 | `string` 32 | 33 | ### url Constraints 34 | 35 | **URI**: the string must be a URI, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 36 | -------------------------------------------------------------------------------- /src/types/docs/definitions-definitions.md: -------------------------------------------------------------------------------- 1 | ## definitions Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-path.md: -------------------------------------------------------------------------------- 1 | ## path Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-paused.md: -------------------------------------------------------------------------------- 1 | ## paused Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-else.md: -------------------------------------------------------------------------------- 1 | ## else Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-if-properties-type.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | unknown 4 | 5 | ## type Constraints 6 | 7 | **constant**: the value of this property must be equal to: 8 | 9 | ```json 10 | "schedule" 11 | ``` 12 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-if-properties.md: -------------------------------------------------------------------------------- 1 | ## properties Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-if.md: -------------------------------------------------------------------------------- 1 | ## if Type 2 | 3 | unknown 4 | 5 | # if Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :------------ | :------------ | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------- | 9 | | [type](#type) | Not specified | Optional | cannot be null | [Function](function-properties-trigger-if-properties-type.md "#/properties/trigger/if/properties/type") | 10 | 11 | ## type 12 | 13 | 14 | 15 | `type` 16 | 17 | * is optional 18 | 19 | * Type: unknown 20 | 21 | * cannot be null 22 | 23 | * defined in: [Function](function-properties-trigger-if-properties-type.md "#/properties/trigger/if/properties/type") 24 | 25 | ### type Type 26 | 27 | unknown 28 | 29 | ### type Constraints 30 | 31 | **constant**: the value of this property must be equal to: 32 | 33 | ```json 34 | "schedule" 35 | ``` 36 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-properties-triggercron.md: -------------------------------------------------------------------------------- 1 | ## cron Type 2 | 3 | `string` ([TriggerCron](function-properties-trigger-properties-triggercron.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-properties-triggerfrequency.md: -------------------------------------------------------------------------------- 1 | ## frequency Type 2 | 3 | `integer` ([TriggerFrequency](function-properties-trigger-properties-triggerfrequency.md)) 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-properties-triggertype.md: -------------------------------------------------------------------------------- 1 | ## type Type 2 | 3 | `string` ([TriggerType](function-properties-trigger-properties-triggertype.md)) 4 | 5 | ## type Constraints 6 | 7 | **enum**: the value of this property must be equal to one of the following values: 8 | 9 | | Value | Explanation | 10 | | :----------------- | :---------- | 11 | | `"schedule"` | | 12 | | `"webhook"` | | 13 | | `"sentinel"` | | 14 | | `"monitor-filter"` | | 15 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-then-oneof-0.md: -------------------------------------------------------------------------------- 1 | ## 0 Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-then-oneof-1.md: -------------------------------------------------------------------------------- 1 | ## 1 Type 2 | 3 | unknown 4 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger-then.md: -------------------------------------------------------------------------------- 1 | ## then Type 2 | 3 | merged type ([Details](function-properties-trigger-then.md)) 4 | 5 | one (and only one) of 6 | 7 | * [Untitled type in Function](function-properties-trigger-then-oneof-0.md "check type definition") 8 | 9 | * [Untitled type in Function](function-properties-trigger-then-oneof-1.md "check type definition") 10 | -------------------------------------------------------------------------------- /src/types/docs/function-properties-trigger.md: -------------------------------------------------------------------------------- 1 | ## trigger Type 2 | 3 | `object` ([Trigger](function-properties-trigger.md)) 4 | 5 | # trigger Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :---------------------- | :-------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------- | 9 | | [type](#type) | `string` | Required | cannot be null | [Function](function-properties-trigger-properties-triggertype.md "#/properties/trigger/properties/type") | 10 | | [cron](#cron) | `string` | Optional | cannot be null | [Function](function-properties-trigger-properties-triggercron.md "#/properties/trigger/properties/cron") | 11 | | [frequency](#frequency) | `integer` | Optional | cannot be null | [Function](function-properties-trigger-properties-triggerfrequency.md "#/properties/trigger/properties/frequency") | 12 | 13 | ## type 14 | 15 | 16 | 17 | `type` 18 | 19 | * is required 20 | 21 | * Type: `string` ([TriggerType](function-properties-trigger-properties-triggertype.md)) 22 | 23 | * cannot be null 24 | 25 | * defined in: [Function](function-properties-trigger-properties-triggertype.md "#/properties/trigger/properties/type") 26 | 27 | ### type Type 28 | 29 | `string` ([TriggerType](function-properties-trigger-properties-triggertype.md)) 30 | 31 | ### type Constraints 32 | 33 | **enum**: the value of this property must be equal to one of the following values: 34 | 35 | | Value | Explanation | 36 | | :----------------- | :---------- | 37 | | `"schedule"` | | 38 | | `"webhook"` | | 39 | | `"sentinel"` | | 40 | | `"monitor-filter"` | | 41 | 42 | ## cron 43 | 44 | 45 | 46 | `cron` 47 | 48 | * is optional 49 | 50 | * Type: `string` ([TriggerCron](function-properties-trigger-properties-triggercron.md)) 51 | 52 | * cannot be null 53 | 54 | * defined in: [Function](function-properties-trigger-properties-triggercron.md "#/properties/trigger/properties/cron") 55 | 56 | ### cron Type 57 | 58 | `string` ([TriggerCron](function-properties-trigger-properties-triggercron.md)) 59 | 60 | ## frequency 61 | 62 | 63 | 64 | `frequency` 65 | 66 | * is optional 67 | 68 | * Type: `integer` ([TriggerFrequency](function-properties-trigger-properties-triggerfrequency.md)) 69 | 70 | * cannot be null 71 | 72 | * defined in: [Function](function-properties-trigger-properties-triggerfrequency.md "#/properties/trigger/properties/frequency") 73 | 74 | ### frequency Type 75 | 76 | `integer` ([TriggerFrequency](function-properties-trigger-properties-triggerfrequency.md)) 77 | -------------------------------------------------------------------------------- /src/types/docs/function.md: -------------------------------------------------------------------------------- 1 | ## Function Type 2 | 3 | `object` ([Function](function.md)) 4 | 5 | # Function Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :------------------ | :-------- | :------- | :------------- | :----------------------------------------------------------------------------- | 9 | | [path](#path) | `string` | Required | cannot be null | [Function](function-properties-path.md "#/properties/path") | 10 | | [relayer](#relayer) | `object` | Optional | cannot be null | [Function](definitions-definitions-relayer.md "#/properties/relayer") | 11 | | [trigger](#trigger) | `object` | Required | cannot be null | [Function](function-properties-trigger.md "#/properties/trigger") | 12 | | [paused](#paused) | `boolean` | Required | cannot be null | [Function](function-properties-paused.md "#/properties/paused") | 13 | 14 | ## path 15 | 16 | 17 | 18 | `path` 19 | 20 | * is required 21 | 22 | * Type: `string` 23 | 24 | * cannot be null 25 | 26 | * defined in: [Function](function-properties-path.md "#/properties/path") 27 | 28 | ### path Type 29 | 30 | `string` 31 | 32 | ## relayer 33 | 34 | 35 | 36 | `relayer` 37 | 38 | * is optional 39 | 40 | * Type: `object` ([Relayer](definitions-definitions-relayer.md)) 41 | 42 | * cannot be null 43 | 44 | * defined in: [Function](definitions-definitions-relayer.md "#/properties/relayer") 45 | 46 | ### relayer Type 47 | 48 | `object` ([Relayer](definitions-definitions-relayer.md)) 49 | 50 | ### relayer Constraints 51 | 52 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 53 | 54 | ## trigger 55 | 56 | 57 | 58 | `trigger` 59 | 60 | * is required 61 | 62 | * Type: `object` ([Trigger](function-properties-trigger.md)) 63 | 64 | * cannot be null 65 | 66 | * defined in: [Function](function-properties-trigger.md "#/properties/trigger") 67 | 68 | ### trigger Type 69 | 70 | `object` ([Trigger](function-properties-trigger.md)) 71 | 72 | ## paused 73 | 74 | 75 | 76 | `paused` 77 | 78 | * is required 79 | 80 | * Type: `boolean` 81 | 82 | * cannot be null 83 | 84 | * defined in: [Function](function-properties-paused.md "#/properties/paused") 85 | 86 | ### paused Type 87 | 88 | `boolean` 89 | -------------------------------------------------------------------------------- /src/types/docs/provider-properties-ssot.md: -------------------------------------------------------------------------------- 1 | ## ssot Type 2 | 3 | `boolean` 4 | -------------------------------------------------------------------------------- /src/types/docs/provider-properties-stackname.md: -------------------------------------------------------------------------------- 1 | ## stackName Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/provider-properties-stage.md: -------------------------------------------------------------------------------- 1 | ## stage Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/provider.md: -------------------------------------------------------------------------------- 1 | ## Provider Type 2 | 3 | `object` ([Provider](provider.md)) 4 | 5 | # Provider Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :---------------------- | :-------- | :------- | :------------- | :----------------------------------------------------------------------------- | 9 | | [stage](#stage) | `string` | Required | cannot be null | [Provider](provider-properties-stage.md "#/properties/stage") | 10 | | [stackName](#stackname) | `string` | Required | cannot be null | [Provider](provider-properties-stackname.md "#/properties/stackName") | 11 | | [ssot](#ssot) | `boolean` | Optional | cannot be null | [Provider](provider-properties-ssot.md "#/properties/ssot") | 12 | 13 | ## stage 14 | 15 | 16 | 17 | `stage` 18 | 19 | * is required 20 | 21 | * Type: `string` 22 | 23 | * cannot be null 24 | 25 | * defined in: [Provider](provider-properties-stage.md "#/properties/stage") 26 | 27 | ### stage Type 28 | 29 | `string` 30 | 31 | ## stackName 32 | 33 | 34 | 35 | `stackName` 36 | 37 | * is required 38 | 39 | * Type: `string` 40 | 41 | * cannot be null 42 | 43 | * defined in: [Provider](provider-properties-stackname.md "#/properties/stackName") 44 | 45 | ### stackName Type 46 | 47 | `string` 48 | 49 | ## ssot 50 | 51 | 52 | 53 | `ssot` 54 | 55 | * is optional 56 | 57 | * Type: `boolean` 58 | 59 | * cannot be null 60 | 61 | * defined in: [Provider](provider-properties-ssot.md "#/properties/ssot") 62 | 63 | ### ssot Type 64 | 65 | `boolean` 66 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-autotasksecrets-properties-global-additionalproperties.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-autotasksecrets-properties-global.md: -------------------------------------------------------------------------------- 1 | ## global Type 2 | 3 | `object` ([Global](resources-properties-resources-properties-autotasksecrets-properties-global.md)) 4 | 5 | # global Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `string` | Optional | cannot be null | [Resources](resources-properties-resources-properties-autotasksecrets-properties-global-additionalproperties.md "#/properties/Resources/properties/secrets/properties/global/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `string` 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](resources-properties-resources-properties-autotasksecrets-properties-global-additionalproperties.md "#/properties/Resources/properties/secrets/properties/global/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `string` 28 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-autotasksecrets-properties-stack-additionalproperties.md: -------------------------------------------------------------------------------- 1 | ## additionalProperties Type 2 | 3 | `string` 4 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-autotasksecrets-properties-stack.md: -------------------------------------------------------------------------------- 1 | ## stack Type 2 | 3 | `object` ([Stack](resources-properties-resources-properties-autotasksecrets-properties-stack.md)) 4 | 5 | # stack Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `string` | Optional | cannot be null | [Resources](resources-properties-resources-properties-autotasksecrets-properties-stack-additionalproperties.md "#/properties/Resources/properties/secrets/properties/stack/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `string` 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](resources-properties-resources-properties-autotasksecrets-properties-stack-additionalproperties.md "#/properties/Resources/properties/secrets/properties/stack/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `string` 28 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-autotasksecrets.md: -------------------------------------------------------------------------------- 1 | ## secrets Type 2 | 3 | `object` ([AutotaskSecrets](resources-properties-resources-properties-autotasksecrets.md)) 4 | 5 | # secrets Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :---------------- | :------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [global](#global) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-autotasksecrets-properties-global.md "#/properties/Resources/properties/secrets/properties/global") | 10 | | [stack](#stack) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-autotasksecrets-properties-stack.md "#/properties/Resources/properties/secrets/properties/stack") | 11 | 12 | ## global 13 | 14 | 15 | 16 | `global` 17 | 18 | * is optional 19 | 20 | * Type: `object` ([Global](resources-properties-resources-properties-autotasksecrets-properties-global.md)) 21 | 22 | * cannot be null 23 | 24 | * defined in: [Resources](resources-properties-resources-properties-autotasksecrets-properties-global.md "#/properties/Resources/properties/secrets/properties/global") 25 | 26 | ### global Type 27 | 28 | `object` ([Global](resources-properties-resources-properties-autotasksecrets-properties-global.md)) 29 | 30 | ## stack 31 | 32 | 33 | 34 | `stack` 35 | 36 | * is optional 37 | 38 | * Type: `object` ([Stack](resources-properties-resources-properties-autotasksecrets-properties-stack.md)) 39 | 40 | * cannot be null 41 | 42 | * defined in: [Resources](resources-properties-resources-properties-autotasksecrets-properties-stack.md "#/properties/Resources/properties/secrets/properties/stack") 43 | 44 | ### stack Type 45 | 46 | `object` ([Stack](resources-properties-resources-properties-autotasksecrets-properties-stack.md)) 47 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-block-explorer-api-keys.md: -------------------------------------------------------------------------------- 1 | ## block-explorer-api-keys Type 2 | 3 | `object` ([Block Explorer Api Keys](resources-properties-resources-properties-block-explorer-api-keys.md)) 4 | 5 | # block-explorer-api-keys Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `object` | Optional | cannot be null | [Resources](definitions-definitions-blockexplorerapikey.md "#/properties/Resources/properties/block-explorer-api-keys/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `object` ([BlockExplorerApiKey](definitions-definitions-blockexplorerapikey.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](definitions-definitions-blockexplorerapikey.md "#/properties/Resources/properties/block-explorer-api-keys/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `object` ([BlockExplorerApiKey](definitions-definitions-blockexplorerapikey.md)) 28 | 29 | ### additionalProperties Constraints 30 | 31 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 32 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-contracts.md: -------------------------------------------------------------------------------- 1 | ## contracts Type 2 | 3 | `object` ([Contracts](resources-properties-resources-properties-contracts.md)) 4 | 5 | # contracts Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `object` | Optional | cannot be null | [Resources](definitions-definitions-contract.md "#/properties/Resources/properties/contracts/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `object` ([Contract](definitions-definitions-contract.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](definitions-definitions-contract.md "#/properties/Resources/properties/contracts/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `object` ([Contract](definitions-definitions-contract.md)) 28 | 29 | ### additionalProperties Constraints 30 | 31 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 32 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-deployment-configs.md: -------------------------------------------------------------------------------- 1 | ## deployment-configs Type 2 | 3 | `object` ([Deployment Configs](resources-properties-resources-properties-deployment-configs.md)) 4 | 5 | # deployment-configs Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `object` | Optional | cannot be null | [Resources](definitions-definitions-deploymentconfig.md "#/properties/Resources/properties/deployment-configs/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `object` ([DeploymentConfig](definitions-definitions-deploymentconfig.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](definitions-definitions-deploymentconfig.md "#/properties/Resources/properties/deployment-configs/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `object` ([DeploymentConfig](definitions-definitions-deploymentconfig.md)) 28 | 29 | ### additionalProperties Constraints 30 | 31 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 32 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-notifications.md: -------------------------------------------------------------------------------- 1 | ## notifications Type 2 | 3 | `object` ([Notifications](resources-properties-resources-properties-notifications.md)) 4 | 5 | # notifications Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `object` | Optional | cannot be null | [Resources](definitions-definitions-notification.md "#/properties/Resources/properties/notifications/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `object` ([Notification](definitions-definitions-notification.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](definitions-definitions-notification.md "#/properties/Resources/properties/notifications/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `object` ([Notification](definitions-definitions-notification.md)) 28 | 29 | ### additionalProperties Constraints 30 | 31 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 32 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-policies.md: -------------------------------------------------------------------------------- 1 | ## policies Type 2 | 3 | `object` ([Policies](resources-properties-resources-properties-policies.md)) 4 | 5 | # policies Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------ | 9 | | Additional Properties | `object` | Optional | cannot be null | [Resources](definitions-definitions-policy.md "#/properties/Resources/properties/policies/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `object` ([Policy](definitions-definitions-policy.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](definitions-definitions-policy.md "#/properties/Resources/properties/policies/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `object` ([Policy](definitions-definitions-policy.md)) 28 | 29 | ### additionalProperties Constraints 30 | 31 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 32 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-relayers.md: -------------------------------------------------------------------------------- 1 | ## relayers Type 2 | 3 | `object` ([Relayers](resources-properties-resources-properties-relayers.md)) 4 | 5 | # relayers Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :------- | :------- | :------------- | :------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | `object` | Optional | cannot be null | [Resources](definitions-definitions-relayer.md "#/properties/Resources/properties/relayers/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `object` ([Relayer](definitions-definitions-relayer.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](definitions-definitions-relayer.md "#/properties/Resources/properties/relayers/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `object` ([Relayer](definitions-definitions-relayer.md)) 28 | 29 | ### additionalProperties Constraints 30 | 31 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 32 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources-properties-sentinels.md: -------------------------------------------------------------------------------- 1 | ## sentinels Type 2 | 3 | `object` ([Sentinels](resources-properties-resources-properties-sentinels.md)) 4 | 5 | # sentinels Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------- | :----- | :------- | :------------- | :--------------------------------------------------------------------------------------------------------------------------- | 9 | | Additional Properties | Merged | Optional | cannot be null | [Resources](definitions-definitions-sentinel.md "#/properties/Resources/properties/sentinels/additionalProperties") | 10 | 11 | ## Additional Properties 12 | 13 | Additional properties are allowed, as long as they follow this schema: 14 | 15 | 16 | 17 | * is optional 18 | 19 | * Type: `object` ([Sentinel](definitions-definitions-sentinel.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](definitions-definitions-sentinel.md "#/properties/Resources/properties/sentinels/additionalProperties") 24 | 25 | ### additionalProperties Type 26 | 27 | `object` ([Sentinel](definitions-definitions-sentinel.md)) 28 | 29 | one (and only one) of 30 | 31 | * [BlockSentinel](definitions-definitions-blocksentinel.md "check type definition") 32 | 33 | * any of 34 | 35 | * [Untitled type in Definitions](definitions-definitions-fortasentinel-anyof-0.md "check type definition") 36 | 37 | * [Untitled type in Definitions](definitions-definitions-fortasentinel-anyof-1.md "check type definition") 38 | 39 | ### additionalProperties Constraints 40 | 41 | **URI reference**: the string must be a URI reference, according to [RFC 3986](https://tools.ietf.org/html/rfc3986 "check the specification") 42 | -------------------------------------------------------------------------------- /src/types/docs/resources-properties-resources.md: -------------------------------------------------------------------------------- 1 | ## Resources Type 2 | 3 | `object` ([Resources](resources-properties-resources.md)) 4 | 5 | # Resources Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :-------------------------------------------------- | :------- | :------- | :------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | 9 | | [notifications](#notifications) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-notifications.md "#/properties/Resources/properties/notifications") | 10 | | [relayers](#relayers) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-relayers.md "#/properties/Resources/properties/relayers") | 11 | | [policies](#policies) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-policies.md "#/properties/Resources/properties/policies") | 12 | | [contracts](#contracts) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-contracts.md "#/properties/Resources/properties/contracts") | 13 | | [secrets](#secrets) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-autotasksecrets.md "#/properties/Resources/properties/secrets") | 14 | | [sentinels](#sentinels) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-sentinels.md "#/properties/Resources/properties/sentinels") | 15 | | [deployment-configs](#deployment-configs) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-deployment-configs.md "#/properties/Resources/properties/deployment-configs") | 16 | | [block-explorer-api-keys](#block-explorer-api-keys) | `object` | Optional | cannot be null | [Resources](resources-properties-resources-properties-block-explorer-api-keys.md "#/properties/Resources/properties/block-explorer-api-keys") | 17 | 18 | ## notifications 19 | 20 | 21 | 22 | `notifications` 23 | 24 | * is optional 25 | 26 | * Type: `object` ([Notifications](resources-properties-resources-properties-notifications.md)) 27 | 28 | * cannot be null 29 | 30 | * defined in: [Resources](resources-properties-resources-properties-notifications.md "#/properties/Resources/properties/notifications") 31 | 32 | ### notifications Type 33 | 34 | `object` ([Notifications](resources-properties-resources-properties-notifications.md)) 35 | 36 | ## relayers 37 | 38 | 39 | 40 | `relayers` 41 | 42 | * is optional 43 | 44 | * Type: `object` ([Relayers](resources-properties-resources-properties-relayers.md)) 45 | 46 | * cannot be null 47 | 48 | * defined in: [Resources](resources-properties-resources-properties-relayers.md "#/properties/Resources/properties/relayers") 49 | 50 | ### relayers Type 51 | 52 | `object` ([Relayers](resources-properties-resources-properties-relayers.md)) 53 | 54 | ## policies 55 | 56 | 57 | 58 | `policies` 59 | 60 | * is optional 61 | 62 | * Type: `object` ([Policies](resources-properties-resources-properties-policies.md)) 63 | 64 | * cannot be null 65 | 66 | * defined in: [Resources](resources-properties-resources-properties-policies.md "#/properties/Resources/properties/policies") 67 | 68 | ### policies Type 69 | 70 | `object` ([Policies](resources-properties-resources-properties-policies.md)) 71 | 72 | ## contracts 73 | 74 | 75 | 76 | `contracts` 77 | 78 | * is optional 79 | 80 | * Type: `object` ([Contracts](resources-properties-resources-properties-contracts.md)) 81 | 82 | * cannot be null 83 | 84 | * defined in: [Resources](resources-properties-resources-properties-contracts.md "#/properties/Resources/properties/contracts") 85 | 86 | ### contracts Type 87 | 88 | `object` ([Contracts](resources-properties-resources-properties-contracts.md)) 89 | 90 | ## secrets 91 | 92 | 93 | 94 | `secrets` 95 | 96 | * is optional 97 | 98 | * Type: `object` ([AutotaskSecrets](resources-properties-resources-properties-autotasksecrets.md)) 99 | 100 | * cannot be null 101 | 102 | * defined in: [Resources](resources-properties-resources-properties-autotasksecrets.md "#/properties/Resources/properties/secrets") 103 | 104 | ### secrets Type 105 | 106 | `object` ([AutotaskSecrets](resources-properties-resources-properties-autotasksecrets.md)) 107 | 108 | ## sentinels 109 | 110 | 111 | 112 | `sentinels` 113 | 114 | * is optional 115 | 116 | * Type: `object` ([Sentinels](resources-properties-resources-properties-sentinels.md)) 117 | 118 | * cannot be null 119 | 120 | * defined in: [Resources](resources-properties-resources-properties-sentinels.md "#/properties/Resources/properties/sentinels") 121 | 122 | ### sentinels Type 123 | 124 | `object` ([Sentinels](resources-properties-resources-properties-sentinels.md)) 125 | 126 | ## deployment-configs 127 | 128 | 129 | 130 | `deployment-configs` 131 | 132 | * is optional 133 | 134 | * Type: `object` ([Deployment Configs](resources-properties-resources-properties-deployment-configs.md)) 135 | 136 | * cannot be null 137 | 138 | * defined in: [Resources](resources-properties-resources-properties-deployment-configs.md "#/properties/Resources/properties/deployment-configs") 139 | 140 | ### deployment-configs Type 141 | 142 | `object` ([Deployment Configs](resources-properties-resources-properties-deployment-configs.md)) 143 | 144 | ## block-explorer-api-keys 145 | 146 | 147 | 148 | `block-explorer-api-keys` 149 | 150 | * is optional 151 | 152 | * Type: `object` ([Block Explorer Api Keys](resources-properties-resources-properties-block-explorer-api-keys.md)) 153 | 154 | * cannot be null 155 | 156 | * defined in: [Resources](resources-properties-resources-properties-block-explorer-api-keys.md "#/properties/Resources/properties/block-explorer-api-keys") 157 | 158 | ### block-explorer-api-keys Type 159 | 160 | `object` ([Block Explorer Api Keys](resources-properties-resources-properties-block-explorer-api-keys.md)) 161 | -------------------------------------------------------------------------------- /src/types/docs/resources.md: -------------------------------------------------------------------------------- 1 | ## Resources Type 2 | 3 | `object` ([Resources](resources.md)) 4 | 5 | # Resources Properties 6 | 7 | | Property | Type | Required | Nullable | Defined by | 8 | | :---------------------- | :------- | :------- | :------------- | :------------------------------------------------------------------------------- | 9 | | [Resources](#resources) | `object` | Optional | cannot be null | [Resources](resources-properties-resources.md "#/properties/Resources") | 10 | 11 | ## Resources 12 | 13 | 14 | 15 | `Resources` 16 | 17 | * is optional 18 | 19 | * Type: `object` ([Resources](resources-properties-resources.md)) 20 | 21 | * cannot be null 22 | 23 | * defined in: [Resources](resources-properties-resources.md "#/properties/Resources") 24 | 25 | ### Resources Type 26 | 27 | `object` ([Resources](resources-properties-resources.md)) 28 | -------------------------------------------------------------------------------- /src/types/schemas/configs/replace-ref-config.ts: -------------------------------------------------------------------------------- 1 | // replace-in-file configuration 2 | module.exports = { 3 | files: ['**/schemas/*.schema.json'], 4 | from: /definitions.schema.json\//g, 5 | to: '', 6 | }; 7 | -------------------------------------------------------------------------------- /src/types/schemas/configs/replace-undefined-config.ts: -------------------------------------------------------------------------------- 1 | // replace-in-file configuration 2 | module.exports = { 3 | files: ['**/docs/*.md'], 4 | from: /undefined/g, 5 | to: '', 6 | }; 7 | -------------------------------------------------------------------------------- /src/types/schemas/defender.schema.json: -------------------------------------------------------------------------------- 1 | {"$schema":"http://json-schema.org/draft-07/schema#","title":"Defender","type":"object","properties":{"key":{"type":"string"},"secret":{"type":"string"}},"required":["key","secret"]} 2 | -------------------------------------------------------------------------------- /src/types/schemas/function.schema.json: -------------------------------------------------------------------------------- 1 | {"$schema":"http://json-schema.org/draft-07/schema#","title":"Function","type":"object","properties":{"path":{"type":"string"},"relayer":{"title":"Relayer","$ref":"#/definitions/relayer","format":"uri-reference"},"trigger":{"title":"Trigger","type":"object","properties":{"type":{"title":"TriggerType","type":"string","enum":["schedule","webhook","sentinel","monitor-filter"]},"cron":{"title":"TriggerCron","type":"string"},"frequency":{"title":"TriggerFrequency","type":"integer"}},"if":{"properties":{"type":{"const":"schedule"}}},"then":{"oneOf":[{"required":["cron"]},{"required":["frequency"]}]},"else":{},"required":["type"]},"paused":{"type":"boolean"}},"required":["name","path","trigger","paused"]} 2 | -------------------------------------------------------------------------------- /src/types/schemas/index.ts: -------------------------------------------------------------------------------- 1 | import DefenderSchemaJson from './defender.schema.json'; 2 | import DefinitionsSchemaJson from './definitions.schema.json'; 3 | import FunctionSchemaJson from './function.schema.json'; 4 | import ProviderSchemaJson from './provider.schema.json'; 5 | import ResourcesSchemaJson from './resources.schema.json'; 6 | 7 | export const DefenderSchema = DefenderSchemaJson; 8 | export const DefinitionsSchema = DefinitionsSchemaJson; 9 | export const FunctionSchema = FunctionSchemaJson; 10 | export const ProviderSchema = ProviderSchemaJson; 11 | export const ResourcesSchema = ResourcesSchemaJson; 12 | -------------------------------------------------------------------------------- /src/types/schemas/provider.schema.json: -------------------------------------------------------------------------------- 1 | {"$schema":"http://json-schema.org/draft-07/schema#","title":"Provider","type":"object","properties":{"stage":{"type":"string"},"stackName":{"type":"string"},"ssot":{"type":"boolean"}},"required":["stage","stackName"]} 2 | -------------------------------------------------------------------------------- /src/types/schemas/resources.schema.json: -------------------------------------------------------------------------------- 1 | {"$schema":"http://json-schema.org/draft-07/schema#","title":"Resources","type":"object","additionalProperties":false,"properties":{"Resources":{"title":"Resources","type":"object","properties":{"notifications":{"title":"Notifications","type":"object","additionalProperties":{"$ref":"#/definitions/notification","format":"uri-reference"}},"relayers":{"title":"Relayers","type":"object","additionalProperties":{"$ref":"#/definitions/relayer","format":"uri-reference"}},"policies":{"title":"Policies","type":"object","additionalProperties":{"$ref":"#/definitions/policy","format":"uri-reference"}},"contracts":{"title":"Contracts","type":"object","additionalProperties":{"$ref":"#/definitions/contract","format":"uri-reference"}},"secrets":{"title":"AutotaskSecrets","type":"object","additionalProperties":false,"properties":{"global":{"title":"Global","type":"object","additionalProperties":{"type":"string"}},"stack":{"title":"Stack","type":"object","additionalProperties":{"type":"string"}}}},"sentinels":{"title":"Sentinels","type":"object","additionalProperties":{"$ref":"#/definitions/sentinel","format":"uri-reference"}},"deployment-configs":{"title":"Deployment Configs","type":"object","additionalProperties":{"$ref":"#/definitions/deploymentConfig","format":"uri-reference"}},"block-explorer-api-keys":{"title":"Block Explorer Api Keys","type":"object","additionalProperties":{"$ref":"#/definitions/blockExplorerApiKey","format":"uri-reference"}}}}}} 2 | -------------------------------------------------------------------------------- /src/utils/logger.ts: -------------------------------------------------------------------------------- 1 | import { Logging } from 'serverless/classes/Plugin'; 2 | import { DefenderAPIError } from '../types'; 3 | 4 | export default class Logger { 5 | private static instance: Logger; 6 | private logger?: Logging; 7 | 8 | private constructor(logging?: Logging) { 9 | if (logging) { 10 | this.logger = logging; 11 | } 12 | } 13 | 14 | public static getInstance(logging?: Logging): Logger { 15 | if (!Logger.instance) { 16 | Logger.instance = new Logger(logging); 17 | } 18 | return Logger.instance; 19 | } 20 | 21 | public progress(name: string, message: string) { 22 | const progress = this.logger?.progress.get(name); 23 | if (progress) progress.update(message); 24 | else this.logger?.progress.create({ message, name }); 25 | } 26 | 27 | public removeProgress(name: string) { 28 | this.logger?.progress.get(name).remove(); 29 | } 30 | 31 | public info(message: any, indentLevel = 0) { 32 | const indents = ` `.repeat(2).repeat(indentLevel); 33 | const args = indents ? [indents + message] : [message]; 34 | this.logger?.log.info(...args); 35 | } 36 | public notice(message: any, indentLevel = 0) { 37 | const indents = ` `.repeat(2).repeat(indentLevel); 38 | const args = indents ? [indents + message] : [message]; 39 | this.logger?.log.notice(...args); 40 | } 41 | public warn(message: any) { 42 | this.logger?.log.warning(message); 43 | } 44 | public success(message: any) { 45 | this.logger?.log.success(message); 46 | } 47 | public error(message: any) { 48 | this.logger?.log.error(message); 49 | } 50 | public stdOut(message: string | string[]) { 51 | this.logger?.writeText(message); 52 | } 53 | public tryLogDefenderError(e: any) { 54 | try { 55 | const defenderAPIError = (e as DefenderAPIError).response.data as any; 56 | this.error(defenderAPIError.message ?? defenderAPIError.Message); 57 | } catch { 58 | if (e.message) this.error(e.message); 59 | else this.error(e); 60 | } 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /src/utils/sanitise.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @notice copied from https://gist.github.com/simonrenoult/2fa79fec8f035b2d35cef0767363b227 3 | * */ 4 | 5 | import _ from 'lodash'; 6 | 7 | export const sanitise = (object: object): object | string | null => { 8 | if (_.isString(object)) return _sanitiseString(object); 9 | if (_.isArray(object)) return _sanitiseArray(object); 10 | if (_.isPlainObject(object)) return _sanitiseObject(object); 11 | return object; 12 | }; 13 | 14 | const _sanitiseString = (string: string) => { 15 | return _.isEmpty(string) ? null : string; 16 | }; 17 | 18 | const _sanitiseArray = (array: Array) => { 19 | return _.filter(_.map(array, sanitise), _isProvided); 20 | }; 21 | 22 | const _sanitiseObject = (object: object) => { 23 | return _.pickBy(_.mapValues(object, sanitise), _isProvided); 24 | }; 25 | 26 | const _isProvided = (value: any) => { 27 | const typeIsNotSupported = !_.isNil(value) && !_.isString(value) && !_.isArray(value) && !_.isPlainObject(value); 28 | return typeIsNotSupported || !_.isEmpty(value); 29 | }; 30 | -------------------------------------------------------------------------------- /template/.gitignore: -------------------------------------------------------------------------------- 1 | # package directories 2 | node_modules 3 | jspm_packages 4 | 5 | # Serverless directories 6 | .serverless 7 | 8 | # Other 9 | .env 10 | *.log 11 | .DS_Store 12 | 13 | # Defender 14 | secrets*.yml 15 | .defender -------------------------------------------------------------------------------- /template/README.md: -------------------------------------------------------------------------------- 1 | # Defender Serverless Plugin 2 | 3 | Defender Serverless is a Serverless Framework plugin for automated resource management on Defender. 4 | 5 | :warning: **This plugin is still under development. Bugs are expected. Use with care.** 6 | 7 | ## Prerequisites 8 | 9 | Serverless Framework: https://www.serverless.com/framework/docs/getting-started/ 10 | 11 | ## Installation 12 | 13 | You can initialise your Serverless project directly using our pre-configured template: 14 | 15 | ``` 16 | sls install --url https://github.com/OpenZeppelin/defender-serverless/tree/main/template -n my-service 17 | ``` 18 | 19 | Note: for the command above to work correctly you need access to this repo. 20 | 21 | Alternatively, you can install it directly into an existing project with: 22 | 23 | `yarn add @openzeppelin/defender-serverless` 24 | 25 | ## Setup 26 | 27 | This plugin allows you to define Autotasks, Sentinels, Notifications, Relayers, Contracts, Policies and Secrets declaratively from a `serverless.yml` and provision them via the CLI using `serverless deploy`. An example template below with an autotask, a relayer, a policy and a single relayer API key defined: 28 | 29 | ```yaml 30 | service: defender-serverless-template 31 | configValidationMode: error 32 | frameworkVersion: '3' 33 | 34 | provider: 35 | name: defender 36 | stage: ${opt:stage, 'dev'} 37 | stackName: 'mystack' 38 | ssot: false 39 | 40 | defender: 41 | key: '${env:TEAM_API_KEY}' 42 | secret: '${env:TEAM_API_SECRET}' 43 | 44 | functions: 45 | autotask-example-1: 46 | name: 'Hello world from serverless' 47 | path: './autotasks/hello-world' 48 | relayer: ${self:resources.Resources.relayers.relayer-1} 49 | trigger: 50 | type: 'schedule' 51 | frequency: 1500 52 | paused: false 53 | 54 | resources: 55 | Resources: 56 | policies: 57 | policy-1: 58 | gas-price-cap: 1000 59 | whitelist-receivers: 60 | - '0x0f06aB75c7DD497981b75CD82F6566e3a5CAd8f2' 61 | eip1559-pricing: true 62 | 63 | relayers: 64 | relayer-1: 65 | name: 'Test Relayer 1' 66 | network: 'sepolia' 67 | min-balance: 1000 68 | policy: ${self:resources.Resources.policies.policy-1} 69 | api-keys: 70 | - key1 71 | 72 | plugins: 73 | - defender-serverless 74 | ``` 75 | 76 | This requires setting the `key` and `secret` under the `defender` property of the YAML file. We recommend using environment variables or a secure (gitignored) configuration file to retrieve these values. Modify the `serverless.yml` accordingly. 77 | 78 | Ensure the Defender Team API Keys are setup with all appropriate API capabilities. 79 | 80 | The `stackName` (e.g. mystack) is combined with the resource key (e.g. relayer-1) to uniquely identify each resource. This identifier is called the `stackResourceId` (e.g. mystack.relayer-1) and allows you to manage multiple deployments within the same Defender team. 81 | 82 | ### SSOT mode 83 | 84 | Under the `provider` property in the `serverless.yml` file, you can optionally add a `ssot` boolean. SSOT or Single Source of Truth, ensures that the state of your stack in Defender is perfectly in sync with the `serverless.yml` template. 85 | This means that all Defender resources, that are not defined in your current template file, are removed from Defender, with the exception of Relayers, upon deployment. If SSOT is not defined in the template, it will default to `false`. 86 | 87 | Any resource removed from the `serverless.yml` file does _not_ get automatically deleted in order to prevent inadvertent resource deletion. For this behaviour to be anticipated, SSOT mode must be enabled. 88 | 89 | ### Secrets (Autotask) 90 | 91 | Autotask secrets can be defined both globally and per stack. Secrets defined under `global` are not affected by changes to the `stackName` and will retain when redeployed under a new stack. Secrets defined under `stack` will be removed (on the condition that [SSOT mode](#SSOT-mode) is enabled) when the stack is redeployed under a new `stackName`. To reference secrets defined under `stack`, use the following format: `_`, for example `mystack_test`. 92 | 93 | ```yaml 94 | secrets: 95 | # optional - global secrets are not affected by stackName changes 96 | global: 97 | foo: ${self:custom.config.secrets.foo} 98 | hello: ${self:custom.config.secrets.hello} 99 | # optional - stack secrets (formatted as _) 100 | stack: 101 | test: ${self:custom.config.secrets.test} 102 | ``` 103 | 104 | ### Types and Schema validation 105 | 106 | We provide auto-generated documentation based on the JSON schemas: 107 | 108 | - [Defender Property](https://github.com/OpenZeppelin/defender-serverless/blob/main/src/types/docs/defender.md) 109 | - [Provider Property](https://github.com/OpenZeppelin/defender-serverless/blob/main/src/types/docs/provider.md) 110 | - [Function (Autotask) Property](https://github.com/OpenZeppelin/defender-serverless/blob/main/src/types/docs/function.md) 111 | - [Resources Property](https://github.com/OpenZeppelin/defender-serverless/blob/main/src/types/docs/resources.md) 112 | 113 | More information on types can be found [here](https://github.com/OpenZeppelin/defender-serverless/blob/main/src/types/index.ts). Specifically, the types preceded with `Y` (e.g. YRelayer). For the schemas, you can check out the [docs-schema](https://github.com/OpenZeppelin/defender-serverless/blob/main/src/types/docs-schemas) folder. 114 | 115 | Additionally, an [example project](https://github.com/OpenZeppelin/defender-serverless/blob/main/examples/defender-test-project/serverless.yml) is available which provides majority of properties that can be defined in the `serverless.yml` file. 116 | 117 | ## Commands 118 | 119 | ### Deploy 120 | 121 | You can use `sls deploy` to deploy your current stack to Defender. 122 | 123 | The deploy takes in an optional `--stage` flag, which is defaulted to `dev` when installed from the template above. 124 | 125 | Moreover, the `serverless.yml` may contain an `ssot` property. More information can be found in the [SSOT mode](#SSOT-mode) section. 126 | 127 | This command will append a log entry in the `.defender` folder of the current working directory. Additionally, if any new relayer keys are created, these will be stored as JSON objects in the `.defender/relayer-keys` folder. 128 | 129 | > When installed from the template, we ensure the `.defender` folder is ignored from any git commits. However, when installing directly, make sure to add this folder it your `.gitignore` file. 130 | 131 | ### Info 132 | 133 | You can use `sls info` to retrieve information on every resource defined in the `serverless.yml` file, including unique identifiers, and properties unique to each Defender component. 134 | 135 | ### Remove 136 | 137 | You can use `sls remove` to remove all defender resources defined in the `serverless.yml` file. 138 | 139 | > To avoid potential loss of funds, Relayers can only be deleted from the Defender UI directly. 140 | 141 | ### Logs 142 | 143 | You can use `sls logs --function --data {...}` to retrieve the latest autotask logs for a given autotask identifier (e.g. mystack.autotask-example-1). This command will run continiously and retrieve logs every 2 seconds. The `--data` flag is optional. 144 | 145 | ### Invoke 146 | 147 | You can use `sls invoke --function ` to manually run an autotask, given its identifier (e.g. mystack.autotask-example-1). 148 | 149 | > Each command has a standard output to a JSON object. 150 | 151 | More information can be found on our documentation page [here](https://docs.openzeppelin.com/defender/serverless-plugin.html) 152 | 153 | ## Caveats 154 | 155 | Errors thrown during the `deploy` process, will not revert any prior changes. Common errors are: 156 | 157 | - Not having set the API key and secret 158 | - Insufficient permissions for the API key 159 | - Validation error of the `serverless.yml` file (see [Types and Schema validation](#Types-and-Schema-validation)) 160 | 161 | Usually, fixing the error and retrying the deploy should suffice as any existing resources will fall within the `update` clause of the deployment. However, if unsure, you can always call `sls remove` to remove the entire stack, and retry. 162 | -------------------------------------------------------------------------------- /template/autotasks/hello-world/index.js: -------------------------------------------------------------------------------- 1 | exports.handler = async function (event) { 2 | console.log(`Hello world from serverless`); 3 | console.log(JSON.stringify(event)); 4 | return `Hello world from serverless`; 5 | }; 6 | -------------------------------------------------------------------------------- /template/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "defender-serverless-template", 3 | "version": "1.0.0", 4 | "description": "Template for the defender-serverless plugin", 5 | "main": "handler.js", 6 | "engines": { 7 | "node": ">14.16" 8 | }, 9 | "scripts": { 10 | "test": "echo \"Error: no test specified\" && exit 1" 11 | }, 12 | "contributors": [ 13 | { 14 | "name": "Santiago Palladino", 15 | "email": "santiago@openzeppelin.com" 16 | }, 17 | { 18 | "name": "Nami Shah", 19 | "email": "nami@openzeppelin.com" 20 | } 21 | ], 22 | "license": "MIT", 23 | "devDependencies": { 24 | "serverless": "^3.20.0", 25 | "@openzeppelin/defender-serverless": "^1.2.0" 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /template/serverless.yml: -------------------------------------------------------------------------------- 1 | service: defender-serverless-template 2 | configValidationMode: error 3 | frameworkVersion: '3' 4 | 5 | provider: 6 | name: defender 7 | stage: ${opt:stage, 'dev'} 8 | stackName: 'mystack' 9 | # SSOT: use this template as a single source of truth. 10 | # This will delete Defender resources (with the exception of Relayers) not found in this template upon deployment. 11 | ssot: false 12 | 13 | defender: 14 | key: '${env:TEAM_API_KEY}' 15 | secret: '${env:TEAM_API_SECRET}' 16 | 17 | functions: 18 | autotask-example-1: 19 | name: 'Hello world from serverless' 20 | path: './autotasks/hello-world' 21 | relayer: ${self:resources.Resources.relayers.relayer-1} 22 | trigger: 23 | type: 'schedule' 24 | frequency: 1500 25 | paused: false 26 | 27 | resources: 28 | Resources: 29 | policies: 30 | policy-1: 31 | gas-price-cap: 1000 32 | whitelist-receivers: 33 | - '0x0f06aB75c7DD497981b75CD82F6566e3a5CAd8f2' 34 | eip1559-pricing: true 35 | private-transactions: true 36 | 37 | relayers: 38 | relayer-1: 39 | name: 'My Relayer' 40 | network: 'sepolia' 41 | min-balance: 1000 42 | policy: ${self:resources.Resources.policies.policy-1} 43 | api-keys: 44 | - key1 45 | 46 | plugins: 47 | - '@openzeppelin/defender-serverless' 48 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "code-style/tsconfig.json", 3 | "compilerOptions": { 4 | "declaration": true, 5 | "outDir": "./lib", 6 | "rootDir": "./src", 7 | "skipLibCheck": true, 8 | "sourceMap": false, 9 | "resolveJsonModule": true 10 | }, 11 | "include": ["./src"], 12 | "exclude": ["./src/types", "node_modules"] 13 | } 14 | --------------------------------------------------------------------------------