@perplexity-ai/perplexity_ai 0.2.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/client.d.mts +4 -6
- package/client.d.mts.map +1 -1
- package/client.d.ts +4 -6
- package/client.d.ts.map +1 -1
- package/client.js +0 -3
- package/client.js.map +1 -1
- package/client.mjs +0 -3
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/async/chat/chat.d.mts +2 -2
- package/resources/async/chat/chat.d.mts.map +1 -1
- package/resources/async/chat/chat.d.ts +2 -2
- package/resources/async/chat/chat.d.ts.map +1 -1
- package/resources/async/chat/completions.d.mts +160 -134
- package/resources/async/chat/completions.d.mts.map +1 -1
- package/resources/async/chat/completions.d.ts +160 -134
- package/resources/async/chat/completions.d.ts.map +1 -1
- package/resources/async/chat/completions.js +25 -7
- package/resources/async/chat/completions.js.map +1 -1
- package/resources/async/chat/completions.mjs +25 -7
- package/resources/async/chat/completions.mjs.map +1 -1
- package/resources/async/chat/index.d.mts +1 -1
- package/resources/async/chat/index.d.mts.map +1 -1
- package/resources/async/chat/index.d.ts +1 -1
- package/resources/async/chat/index.d.ts.map +1 -1
- package/resources/chat/completions.d.mts +115 -83
- package/resources/chat/completions.d.mts.map +1 -1
- package/resources/chat/completions.d.ts +115 -83
- package/resources/chat/completions.d.ts.map +1 -1
- package/resources/chat/completions.js +1 -2
- package/resources/chat/completions.js.map +1 -1
- package/resources/chat/completions.mjs +1 -2
- package/resources/chat/completions.mjs.map +1 -1
- package/resources/index.d.mts +0 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +0 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +1 -3
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +0 -1
- package/resources/index.mjs.map +1 -1
- package/resources/search.d.mts +1 -70
- package/resources/search.d.mts.map +1 -1
- package/resources/search.d.ts +1 -70
- package/resources/search.d.ts.map +1 -1
- package/resources/search.js +1 -1
- package/resources/search.mjs +1 -1
- package/resources/shared.d.mts +310 -25
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +310 -25
- package/resources/shared.d.ts.map +1 -1
- package/src/client.ts +4 -12
- package/src/resources/async/chat/chat.ts +2 -2
- package/src/resources/async/chat/completions.ts +263 -142
- package/src/resources/async/chat/index.ts +1 -1
- package/src/resources/chat/completions.ts +181 -85
- package/src/resources/index.ts +0 -1
- package/src/resources/search.ts +1 -70
- package/src/resources/shared.ts +434 -25
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/resources/content.d.mts +0 -55
- package/resources/content.d.mts.map +0 -1
- package/resources/content.d.ts +0 -55
- package/resources/content.d.ts.map +0 -1
- package/resources/content.js +0 -15
- package/resources/content.js.map +0 -1
- package/resources/content.mjs +0 -11
- package/resources/content.mjs.map +0 -1
- package/src/resources/content.ts +0 -70
package/src/resources/content.ts
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
-
|
|
3
|
-
import { APIResource } from '../core/resource';
|
|
4
|
-
import { APIPromise } from '../core/api-promise';
|
|
5
|
-
import { RequestOptions } from '../internal/request-options';
|
|
6
|
-
|
|
7
|
-
export class Content extends APIResource {
|
|
8
|
-
/**
|
|
9
|
-
* Retrieve the full content from specified URLs
|
|
10
|
-
*/
|
|
11
|
-
create(body: ContentCreateParams, options?: RequestOptions): APIPromise<ContentCreateResponse> {
|
|
12
|
-
return this._client.post('/content', { body, ...options });
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Response containing the retrieved content from URLs
|
|
18
|
-
*/
|
|
19
|
-
export interface ContentCreateResponse {
|
|
20
|
-
/**
|
|
21
|
-
* Unique identifier for this content retrieval request
|
|
22
|
-
*/
|
|
23
|
-
id: string;
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* Array of content objects retrieved from the requested URLs
|
|
27
|
-
*/
|
|
28
|
-
results: Array<ContentCreateResponse.Result>;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export namespace ContentCreateResponse {
|
|
32
|
-
/**
|
|
33
|
-
* Content retrieved from a specific URL
|
|
34
|
-
*/
|
|
35
|
-
export interface Result {
|
|
36
|
-
/**
|
|
37
|
-
* The full text content of the web page or document
|
|
38
|
-
*/
|
|
39
|
-
content: string;
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* The title of the web page or document
|
|
43
|
-
*/
|
|
44
|
-
title: string;
|
|
45
|
-
|
|
46
|
-
/**
|
|
47
|
-
* The URL of the web page or document
|
|
48
|
-
*/
|
|
49
|
-
url: string;
|
|
50
|
-
|
|
51
|
-
/**
|
|
52
|
-
* The publication date of the content (if available)
|
|
53
|
-
*/
|
|
54
|
-
date?: string | null;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
export interface ContentCreateParams {
|
|
59
|
-
/**
|
|
60
|
-
* List of URLs to retrieve content from
|
|
61
|
-
*/
|
|
62
|
-
urls: Array<string>;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
export declare namespace Content {
|
|
66
|
-
export {
|
|
67
|
-
type ContentCreateResponse as ContentCreateResponse,
|
|
68
|
-
type ContentCreateParams as ContentCreateParams,
|
|
69
|
-
};
|
|
70
|
-
}
|