Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.2.0"
".": "0.2.1"
}
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 13
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/parallel-web%2Fparallel-sdk-e853fc79f3b41f00b3934fcc2e4c2813aa9f38528548f5f596e2b11ea833019b.yml
openapi_spec_hash: 34ed7e373927037fce6fd33d9bb60389
config_hash: ae63572e3769dcd1b11e587f039e211a
config_hash: 49716a82995763fddc4308b0b302f1cb
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 0.2.1 (2025-10-21)

Full Changelog: [v0.2.0...v0.2.1](https://github.com/parallel-web/parallel-sdk-typescript/compare/v0.2.0...v0.2.1)

### Features

* **api:** manual updates ([1215c78](https://github.com/parallel-web/parallel-sdk-typescript/commit/1215c7868330a32b185163a1234db5a1b5b23e3c))

## 0.2.0 (2025-10-21)

Full Changelog: [v0.1.2...v0.2.0](https://github.com/parallel-web/parallel-sdk-typescript/compare/v0.1.2...v0.2.0)
Expand Down
1 change: 1 addition & 0 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ Types:
- <code><a href="./src/resources/beta/beta.ts">ExtractError</a></code>
- <code><a href="./src/resources/beta/beta.ts">ExtractResponse</a></code>
- <code><a href="./src/resources/beta/beta.ts">ExtractResult</a></code>
- <code><a href="./src/resources/beta/beta.ts">FetchPolicy</a></code>
- <code><a href="./src/resources/beta/beta.ts">SearchResult</a></code>
- <code><a href="./src/resources/beta/beta.ts">WebSearchResult</a></code>

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "parallel-web",
"version": "0.2.0",
"version": "0.2.1",
"description": "The official TypeScript library for the Parallel API",
"author": "Parallel <support@parallel.ai>",
"types": "dist/index.d.ts",
Expand Down
61 changes: 31 additions & 30 deletions src/resources/beta/beta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,35 @@ export interface ExtractResult {
url: string;
}

/**
* Fetch policy.
*
* Determines when to return content from the cache (faster) vs fetching live
* content (fresher).
*/
export interface FetchPolicy {
/**
* If false, fallback to cached content older than max-age if live fetch fails or
* times out. If true, returns an error instead.
*/
disable_cache_fallback?: boolean;

/**
* Maximum age of cached content in seconds to trigger a live fetch. Minimum value
* 600 seconds (10 minutes). If not provided, a dynamic age policy will be used
* based on the search objective and url.
*/
max_age_seconds?: number | null;

/**
* Timeout in seconds for fetching live content if unavailable in cache. If
* unspecified a dynamic timeout will be used based on the url, generally 15
* seconds for simple pages and up to 60 seconds for complex pages requiring
* javascript or PDF rendering.
*/
timeout_seconds?: number | null;
}

/**
* Output for the Search API.
*/
Expand Down Expand Up @@ -206,7 +235,7 @@ export interface BetaExtractParams {
* Determines when to return content from the cache (faster) vs fetching live
* content (fresher).
*/
fetch_policy?: BetaExtractParams.FetchPolicy | null;
fetch_policy?: FetchPolicy | null;

/**
* Body param: Include full content from each URL. Note that if neither objective
Expand All @@ -233,35 +262,6 @@ export interface BetaExtractParams {
}

export namespace BetaExtractParams {
/**
* Fetch policy.
*
* Determines when to return content from the cache (faster) vs fetching live
* content (fresher).
*/
export interface FetchPolicy {
/**
* If false, fallback to cached content older than max-age if live fetch fails or
* times out. If true, returns an error instead.
*/
disable_cache_fallback?: boolean;

/**
* Maximum age of cached content in seconds to trigger a live fetch. Minimum value
* 600 seconds (10 minutes). If not provided, a dynamic age policy will be used
* based on the search objective and url.
*/
max_age_seconds?: number | null;

/**
* Timeout in seconds for fetching live content if unavailable in cache. If
* unspecified a dynamic timeout will be used based on the url, generally 15
* seconds for simple pages and up to 60 seconds for complex pages requiring
* javascript or PDF rendering.
*/
timeout_seconds?: number | null;
}

/**
* Optional settings for returning full content.
*/
Expand Down Expand Up @@ -328,6 +328,7 @@ export declare namespace Beta {
type ExtractError as ExtractError,
type ExtractResponse as ExtractResponse,
type ExtractResult as ExtractResult,
type FetchPolicy as FetchPolicy,
type SearchResult as SearchResult,
type WebSearchResult as WebSearchResult,
type BetaExtractParams as BetaExtractParams,
Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = '0.2.0'; // x-release-please-version
export const VERSION = '0.2.1'; // x-release-please-version