From d786d3565f74f434f029485ad5785a8bdd498c38 Mon Sep 17 00:00:00 2001 From: AlvaroLuken Date: Fri, 19 Dec 2025 10:27:37 -0800 Subject: [PATCH 1/3] remove blocks by timestamp ep --- .../pricing/compute-unit-costs.mdx | 1 - fern/docs.yml | 3 - src/openapi/blocks/blocks.yaml | 135 ------------------ 3 files changed, 139 deletions(-) delete mode 100644 src/openapi/blocks/blocks.yaml diff --git a/fern/api-reference/pricing-resources/pricing/compute-unit-costs.mdx b/fern/api-reference/pricing-resources/pricing/compute-unit-costs.mdx index 3d3b5e058..f93e761d6 100644 --- a/fern/api-reference/pricing-resources/pricing/compute-unit-costs.mdx +++ b/fern/api-reference/pricing-resources/pricing/compute-unit-costs.mdx @@ -312,7 +312,6 @@ We want builders to be able to use as much of the NFT API as they need without w | Method | CU | | ------------------------------- | --- | -| blocks/by-timestamp | 10 | | alchemy\_getTransactionReceipts | 250 | # Wallet APIs diff --git a/fern/docs.yml b/fern/docs.yml index a8d9e3a6f..e5f88f06b 100644 --- a/fern/docs.yml +++ b/fern/docs.yml @@ -890,9 +890,6 @@ navigation: contents: - page: Utility APIs Overview path: api-reference/data/utility-apis/utility-apis-overview.mdx - - api: API Reference - api-name: blocks - flattened: true - api: Transactions Receipts Endpoints api-name: transactions-receipt slug: utility-apis diff --git a/src/openapi/blocks/blocks.yaml b/src/openapi/blocks/blocks.yaml deleted file mode 100644 index 9ea7b345b..000000000 --- a/src/openapi/blocks/blocks.yaml +++ /dev/null @@ -1,135 +0,0 @@ -# yaml-language-server: $schema=https://spec.openapis.org/oas/3.1/schema/2022-10-07 - -openapi: 3.1.0 -info: - title: "⛓️ Block Timestamp API" - version: "1.0" -servers: - - url: https://api.g.alchemy.com/data/v1 -security: - - apiKey: [] -paths: - "/{apiKey}/utility/blocks/by-timestamp": - get: - summary: Blocks by Timestamp - description: Fetches the first block before or after a given timestamp. Returns the block's number and on-chain timestamp. - tags: - - "Blocks API Endpoints" - parameters: - - $ref: "#/components/parameters/apiKey" - - $ref: "#/components/parameters/networks" - - $ref: "#/components/parameters/timestamp" - - $ref: "#/components/parameters/direction" - responses: - "200": - description: Successful response - content: - application/json: - schema: - $ref: "#/components/schemas/BlockTimestampResponse" - "400": - description: "Bad Request: Malformed request or missing parameters." - content: - application/json: - schema: - $ref: "#/components/schemas/ErrorResponse" - "429": - description: "Too Many Requests: Rate limit exceeded." - content: - application/json: - schema: - $ref: "#/components/schemas/ErrorResponse" - operationId: blocks-by-timestamp -components: - securitySchemes: - apiKey: - type: http - scheme: Bearer - bearerFormat: API_KEY - description: An API key that will be supplied in a named header. - parameters: - apiKey: - name: apiKey - in: path - required: true - schema: - type: string - default: docs-demo - description: For higher throughput, [create your own API key](https://dashboard.alchemy.com/signup) - networks: - name: networks - in: query - required: true - schema: - type: array - minItems: 1 - maxItems: 3 - items: - type: string - default: eth-mainnet - description: Array of networks to query on. The response will be an array with one block per network. Find network enums [here](https://dashboard.alchemy.com/chains) - timestamp: - name: timestamp - in: query - required: true - schema: - type: string - default: "2025-02-28T19:38:57Z" - description: Unix or ISO timestamp - direction: - name: direction - in: query - required: true - schema: - type: string - enum: - - BEFORE - - AFTER - default: AFTER - description: Return the first block "BEFORE" or "AFTER" the provided timestamp - schemas: - ErrorResponse: - type: object - properties: - error: - type: object - properties: - message: - type: string - description: Detailed error message. - required: - - message - description: Error details. - required: - - error - BlockTimestampResponse: - type: object - properties: - data: - type: array - description: List of blocks - items: - $ref: "#/components/schemas/BlockTimestampResponseItem" - required: - - data - BlockTimestampResponseItem: - type: object - properties: - network: - type: string - description: Network identifier - block: - type: object - properties: - number: - type: integer - description: Block number - timestamp: - type: string - description: ISO timestamp of the block - required: - - number - - timestamp - required: - - network - - block From c0ae9e2be020a69353fc51a982312715ae4bbe1c Mon Sep 17 00:00:00 2001 From: AlvaroLuken Date: Fri, 19 Dec 2025 10:34:14 -0800 Subject: [PATCH 2/3] remove block specs file --- fern/apis/blocks/generators.yaml | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 fern/apis/blocks/generators.yaml diff --git a/fern/apis/blocks/generators.yaml b/fern/apis/blocks/generators.yaml deleted file mode 100644 index 2f703671c..000000000 --- a/fern/apis/blocks/generators.yaml +++ /dev/null @@ -1,3 +0,0 @@ -api: - specs: - - openapi: ../../api-specs/alchemy/rest/blocks.json From 56b7c9a5c6feb1795dd1dda5f414eda0d9089bb3 Mon Sep 17 00:00:00 2001 From: AlvaroLuken Date: Fri, 19 Dec 2025 10:44:23 -0800 Subject: [PATCH 3/3] update utility api overview --- .../api-reference/data/utility-apis/utility-apis-overview.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fern/api-reference/data/utility-apis/utility-apis-overview.mdx b/fern/api-reference/data/utility-apis/utility-apis-overview.mdx index fd4a7abc3..2abebab02 100644 --- a/fern/api-reference/data/utility-apis/utility-apis-overview.mdx +++ b/fern/api-reference/data/utility-apis/utility-apis-overview.mdx @@ -9,6 +9,6 @@ slug: reference/utility-api-overview An enhanced API that gets all transaction receipts for a given block by number or block hash. -Fetch all transaction receipts for a **block number** or a **block hash** in one API call using the [alchemy\_getTransactionReceipts](/reference/alchemy-gettransactionreceipts) method - for mainnet and testnets on Ethereum, Polygon, Optimism, and Arbitrum. +Fetch all transaction receipts for a **block number** or a **block hash** in one API call using the [alchemy\_getTransactionReceipts](/docs/data/utility-apis/transactions-receipts-endpoints/alchemy-get-transaction-receipts) method - for mainnet and testnets on Ethereum, Polygon, Optimism, and Arbitrum. -The Transaction Receipts API [uses less Compute Units (CUs)](/reference/compute-units) then batching all the [eth\_getTransactionReceipt](/reference/eth-gettransactionreceipt) calls for each transaction hash - **saving you on compute cost**. +The Transaction Receipts API [uses less Compute Units (CUs)](/reference/compute-units) then batching all the [eth\_getTransactionReceipt](/docs/chains/ethereum/ethereum-api-endpoints/eth-get-transaction-receipt) calls for each transaction hash - **saving you on compute cost**.