newscatcher-catchall-sdk 1.3.1 → 1.5.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/README.md +62 -1
- package/dist/cjs/BaseClient.js +2 -2
- package/dist/cjs/Client.d.ts +6 -0
- package/dist/cjs/Client.js +16 -6
- package/dist/cjs/api/errors/BadRequestError.d.ts +1 -2
- package/dist/cjs/api/errors/UnauthorizedError.d.ts +6 -0
- package/dist/cjs/api/errors/UnauthorizedError.js +54 -0
- package/dist/cjs/api/errors/index.d.ts +1 -0
- package/dist/cjs/api/errors/index.js +1 -0
- package/dist/cjs/api/resources/datasets/client/Client.d.ts +245 -0
- package/dist/cjs/api/resources/datasets/client/Client.js +790 -0
- package/dist/cjs/api/resources/datasets/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/datasets/client/index.js +17 -0
- package/dist/cjs/api/resources/datasets/client/requests/AddEntitiesToDatasetRequest.d.ts +15 -0
- package/dist/cjs/api/resources/datasets/client/requests/AddEntitiesToDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/CreateDatasetFromCsvRequest.d.ts +16 -0
- package/dist/cjs/api/resources/datasets/client/requests/CreateDatasetFromCsvRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/CreateDatasetRequest.d.ts +16 -0
- package/dist/cjs/api/resources/datasets/client/requests/CreateDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/DeleteDatasetRequest.d.ts +10 -0
- package/dist/cjs/api/resources/datasets/client/requests/DeleteDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/GetDatasetRequest.d.ts +10 -0
- package/dist/cjs/api/resources/datasets/client/requests/GetDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/GetDatasetStatusHistoryRequest.d.ts +10 -0
- package/dist/cjs/api/resources/datasets/client/requests/GetDatasetStatusHistoryRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/ListDatasetsRequest.d.ts +21 -0
- package/dist/cjs/api/resources/datasets/client/requests/ListDatasetsRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/ListEntitiesInDatasetRequest.d.ts +21 -0
- package/dist/cjs/api/resources/datasets/client/requests/ListEntitiesInDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/RemoveEntitiesFromDatasetRequest.d.ts +15 -0
- package/dist/cjs/api/resources/datasets/client/requests/RemoveEntitiesFromDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/UpdateDatasetRequest.d.ts +16 -0
- package/dist/cjs/api/resources/datasets/client/requests/UpdateDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/UploadCsvToDatasetRequest.d.ts +14 -0
- package/dist/cjs/api/resources/datasets/client/requests/UploadCsvToDatasetRequest.js +3 -0
- package/dist/cjs/api/resources/datasets/client/requests/index.d.ts +11 -0
- package/dist/cjs/api/resources/datasets/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/datasets/exports.d.ts +2 -0
- package/dist/cjs/api/resources/datasets/exports.js +21 -0
- package/dist/cjs/api/resources/datasets/index.d.ts +1 -0
- package/dist/cjs/api/resources/datasets/index.js +17 -0
- package/dist/cjs/api/resources/entities/client/Client.d.ts +164 -0
- package/dist/cjs/api/resources/entities/client/Client.js +473 -0
- package/dist/cjs/api/resources/entities/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/entities/client/index.js +17 -0
- package/dist/cjs/api/resources/entities/client/requests/CreateEntitiesBatchRequest.d.ts +35 -0
- package/dist/cjs/api/resources/entities/client/requests/CreateEntitiesBatchRequest.js +3 -0
- package/dist/cjs/api/resources/entities/client/requests/DeleteEntityRequest.d.ts +10 -0
- package/dist/cjs/api/resources/entities/client/requests/DeleteEntityRequest.js +3 -0
- package/dist/cjs/api/resources/entities/client/requests/GetEntityRequest.d.ts +10 -0
- package/dist/cjs/api/resources/entities/client/requests/GetEntityRequest.js +3 -0
- package/dist/cjs/api/resources/entities/client/requests/ListEntitiesRequest.d.ts +19 -0
- package/dist/cjs/api/resources/entities/client/requests/ListEntitiesRequest.js +3 -0
- package/dist/cjs/api/resources/entities/client/requests/UpdateEntityRequest.d.ts +22 -0
- package/dist/cjs/api/resources/entities/client/requests/UpdateEntityRequest.js +3 -0
- package/dist/cjs/api/resources/entities/client/requests/index.d.ts +5 -0
- package/dist/cjs/api/resources/entities/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/entities/exports.d.ts +2 -0
- package/dist/cjs/api/resources/entities/exports.js +21 -0
- package/dist/cjs/api/resources/entities/index.d.ts +1 -0
- package/dist/cjs/api/resources/entities/index.js +17 -0
- package/dist/cjs/api/resources/index.d.ts +4 -0
- package/dist/cjs/api/resources/index.js +5 -1
- package/dist/cjs/api/resources/jobs/client/Client.d.ts +47 -25
- package/dist/cjs/api/resources/jobs/client/Client.js +136 -64
- package/dist/cjs/api/resources/jobs/client/requests/DeleteJobRequest.d.ts +10 -0
- package/dist/cjs/api/resources/jobs/client/requests/DeleteJobRequest.js +3 -0
- package/dist/cjs/api/resources/jobs/client/requests/GetUserJobsRequest.d.ts +5 -0
- package/dist/cjs/api/resources/jobs/client/requests/SubmitRequestDto.d.ts +6 -0
- package/dist/cjs/api/resources/jobs/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/monitors/client/Client.d.ts +73 -34
- package/dist/cjs/api/resources/monitors/client/Client.js +207 -77
- package/dist/cjs/api/resources/monitors/client/requests/DeleteMonitorRequest.d.ts +10 -0
- package/dist/cjs/api/resources/monitors/client/requests/DeleteMonitorRequest.js +3 -0
- package/dist/cjs/api/resources/monitors/client/requests/GetMonitorStatusHistoryRequest.d.ts +10 -0
- package/dist/cjs/api/resources/monitors/client/requests/GetMonitorStatusHistoryRequest.js +3 -0
- package/dist/cjs/api/resources/monitors/client/requests/ListMonitorsRequest.d.ts +5 -0
- package/dist/cjs/api/resources/monitors/client/requests/index.d.ts +2 -0
- package/dist/cjs/api/types/AdditionalAttributes.d.ts +7 -0
- package/dist/cjs/api/types/AdditionalAttributes.js +3 -0
- package/dist/cjs/api/types/CompanyAttributes.d.ts +17 -0
- package/dist/cjs/api/types/CompanyAttributes.js +3 -0
- package/dist/cjs/api/types/ConnectedEntity.d.ts +30 -0
- package/dist/cjs/api/types/ConnectedEntity.js +3 -0
- package/dist/cjs/api/types/CreateDatasetCsvResponse.d.ts +10 -0
- package/dist/cjs/api/types/CreateDatasetCsvResponse.js +3 -0
- package/dist/cjs/api/types/CreateEntitiesBatchResponse.d.ts +7 -0
- package/dist/cjs/api/types/CreateEntitiesBatchResponse.js +3 -0
- package/dist/cjs/api/types/CreateEntityRequest.d.ts +13 -0
- package/dist/cjs/api/types/CreateEntityRequest.js +3 -0
- package/dist/cjs/api/types/CreateEntityResponse.d.ts +6 -0
- package/dist/cjs/api/types/CreateEntityResponse.js +3 -0
- package/dist/cjs/api/types/DatasetEntityIdsRequest.d.ts +4 -0
- package/dist/cjs/api/types/DatasetEntityIdsRequest.js +3 -0
- package/dist/cjs/api/types/DatasetEntityListResponse.d.ts +11 -0
- package/dist/cjs/api/types/DatasetEntityListResponse.js +3 -0
- package/dist/cjs/api/types/DatasetListResponse.d.ts +11 -0
- package/dist/cjs/api/types/DatasetListResponse.js +3 -0
- package/dist/cjs/api/types/DatasetResponse.d.ts +20 -0
- package/dist/cjs/api/types/DatasetResponse.js +3 -0
- package/dist/cjs/api/types/DatasetSortBy.d.ts +7 -0
- package/dist/cjs/api/types/DatasetSortBy.js +10 -0
- package/dist/cjs/api/types/DatasetStatus.d.ts +15 -0
- package/dist/cjs/api/types/DatasetStatus.js +18 -0
- package/dist/cjs/api/types/DatasetStatusEntry.d.ts +11 -0
- package/dist/cjs/api/types/DatasetStatusEntry.js +3 -0
- package/dist/cjs/api/types/DatasetStatusHistoryResponse.d.ts +7 -0
- package/dist/cjs/api/types/DatasetStatusHistoryResponse.js +3 -0
- package/dist/cjs/api/types/DeleteJobResponseDto.d.ts +8 -0
- package/dist/cjs/api/types/DeleteJobResponseDto.js +3 -0
- package/dist/cjs/api/types/DeleteMonitorResponseDto.d.ts +8 -0
- package/dist/cjs/api/types/DeleteMonitorResponseDto.js +3 -0
- package/dist/cjs/api/types/EnrichmentType.d.ts +3 -1
- package/dist/cjs/api/types/EnrichmentType.js +3 -1
- package/dist/cjs/api/types/EntityListResponse.d.ts +11 -0
- package/dist/cjs/api/types/EntityListResponse.js +3 -0
- package/dist/cjs/api/types/EntityResponse.d.ts +20 -0
- package/dist/cjs/api/types/EntityResponse.js +3 -0
- package/dist/cjs/api/types/EntitySortBy.d.ts +7 -0
- package/dist/cjs/api/types/EntitySortBy.js +10 -0
- package/dist/cjs/api/types/EntityStatus.d.ts +15 -0
- package/dist/cjs/api/types/EntityStatus.js +18 -0
- package/dist/cjs/api/types/EntitySummary.d.ts +18 -0
- package/dist/cjs/api/types/EntitySummary.js +3 -0
- package/dist/cjs/api/types/EntityType.d.ts +11 -0
- package/dist/cjs/api/types/EntityType.js +14 -0
- package/dist/cjs/api/types/EntityValidationErrorBody.d.ts +16 -0
- package/dist/cjs/api/types/EntityValidationErrorBody.js +3 -0
- package/dist/cjs/api/types/ManageEntitiesResponse.d.ts +6 -0
- package/dist/cjs/api/types/ManageEntitiesResponse.js +3 -0
- package/dist/cjs/api/types/MonitorListItemDto.d.ts +2 -0
- package/dist/cjs/api/types/MonitorRecord.d.ts +1 -0
- package/dist/cjs/api/types/MonitorStatusEntry.d.ts +68 -0
- package/dist/cjs/api/types/MonitorStatusEntry.js +27 -0
- package/dist/cjs/api/types/MonitorStatusHistoryResponseDto.d.ts +13 -0
- package/dist/cjs/api/types/MonitorStatusHistoryResponseDto.js +3 -0
- package/dist/cjs/api/types/OwnershipFilter.d.ts +14 -0
- package/dist/cjs/api/types/OwnershipFilter.js +17 -0
- package/dist/cjs/api/types/PullJobResponseDto.d.ts +2 -0
- package/dist/cjs/api/types/Record_.d.ts +5 -0
- package/dist/cjs/api/types/SharingInfo.d.ts +24 -0
- package/dist/cjs/api/types/SharingInfo.js +13 -0
- package/dist/cjs/api/types/SkippedRow.d.ts +13 -0
- package/dist/cjs/api/types/SkippedRow.js +3 -0
- package/dist/cjs/api/types/SortOrder.d.ts +11 -0
- package/dist/cjs/api/types/SortOrder.js +14 -0
- package/dist/cjs/api/types/UploadCsvToDatasetResponse.d.ts +8 -0
- package/dist/cjs/api/types/UploadCsvToDatasetResponse.js +3 -0
- package/dist/cjs/api/types/UserJob.d.ts +3 -0
- package/dist/cjs/api/types/ValidationReport.d.ts +17 -0
- package/dist/cjs/api/types/ValidationReport.js +3 -0
- package/dist/cjs/api/types/index.d.ts +33 -0
- package/dist/cjs/api/types/index.js +33 -0
- package/dist/cjs/core/auth/BasicAuth.d.ts +2 -2
- package/dist/cjs/core/auth/BasicAuth.js +7 -1
- package/dist/cjs/core/exports.d.ts +1 -0
- package/dist/cjs/core/exports.js +1 -0
- package/dist/cjs/core/fetcher/Fetcher.d.ts +3 -0
- package/dist/cjs/core/fetcher/Fetcher.js +11 -1
- package/dist/cjs/core/file/exports.d.ts +1 -0
- package/dist/cjs/core/file/exports.js +2 -0
- package/dist/cjs/core/file/file.d.ts +10 -0
- package/dist/cjs/core/file/file.js +222 -0
- package/dist/cjs/core/file/index.d.ts +2 -0
- package/dist/cjs/core/file/index.js +18 -0
- package/dist/cjs/core/file/types.d.ts +66 -0
- package/dist/cjs/core/file/types.js +2 -0
- package/dist/cjs/core/form-data-utils/FormDataWrapper.d.ts +15 -0
- package/dist/cjs/core/form-data-utils/FormDataWrapper.js +185 -0
- package/dist/cjs/core/form-data-utils/encodeAsFormParameter.d.ts +1 -0
- package/dist/cjs/core/form-data-utils/encodeAsFormParameter.js +12 -0
- package/dist/cjs/core/form-data-utils/index.d.ts +2 -0
- package/dist/cjs/core/form-data-utils/index.js +20 -0
- package/dist/cjs/core/index.d.ts +2 -0
- package/dist/cjs/core/index.js +3 -1
- package/dist/cjs/core/url/QueryStringBuilder.d.ts +47 -0
- package/dist/cjs/core/url/QueryStringBuilder.js +83 -0
- package/dist/cjs/core/url/index.d.ts +1 -0
- package/dist/cjs/core/url/index.js +3 -1
- package/dist/cjs/core/url/qs.d.ts +2 -1
- package/dist/cjs/core/url/qs.js +24 -12
- package/dist/cjs/errors/CatchAllApiError.d.ts +3 -1
- package/dist/cjs/errors/CatchAllApiError.js +4 -1
- package/dist/cjs/errors/CatchAllApiTimeoutError.d.ts +4 -1
- package/dist/cjs/errors/CatchAllApiTimeoutError.js +4 -1
- package/dist/cjs/errors/handleNonStatusCodeError.js +4 -1
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/Client.d.mts +6 -0
- package/dist/esm/Client.mjs +10 -0
- package/dist/esm/api/errors/BadRequestError.d.mts +1 -2
- package/dist/esm/api/errors/UnauthorizedError.d.mts +6 -0
- package/dist/esm/api/errors/UnauthorizedError.mjs +17 -0
- package/dist/esm/api/errors/index.d.mts +1 -0
- package/dist/esm/api/errors/index.mjs +1 -0
- package/dist/esm/api/resources/datasets/client/Client.d.mts +245 -0
- package/dist/esm/api/resources/datasets/client/Client.mjs +753 -0
- package/dist/esm/api/resources/datasets/client/index.d.mts +1 -0
- package/dist/esm/api/resources/datasets/client/index.mjs +1 -0
- package/dist/esm/api/resources/datasets/client/requests/AddEntitiesToDatasetRequest.d.mts +15 -0
- package/dist/esm/api/resources/datasets/client/requests/AddEntitiesToDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/CreateDatasetFromCsvRequest.d.mts +16 -0
- package/dist/esm/api/resources/datasets/client/requests/CreateDatasetFromCsvRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/CreateDatasetRequest.d.mts +16 -0
- package/dist/esm/api/resources/datasets/client/requests/CreateDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/DeleteDatasetRequest.d.mts +10 -0
- package/dist/esm/api/resources/datasets/client/requests/DeleteDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/GetDatasetRequest.d.mts +10 -0
- package/dist/esm/api/resources/datasets/client/requests/GetDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/GetDatasetStatusHistoryRequest.d.mts +10 -0
- package/dist/esm/api/resources/datasets/client/requests/GetDatasetStatusHistoryRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/ListDatasetsRequest.d.mts +21 -0
- package/dist/esm/api/resources/datasets/client/requests/ListDatasetsRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/ListEntitiesInDatasetRequest.d.mts +21 -0
- package/dist/esm/api/resources/datasets/client/requests/ListEntitiesInDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/RemoveEntitiesFromDatasetRequest.d.mts +15 -0
- package/dist/esm/api/resources/datasets/client/requests/RemoveEntitiesFromDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/UpdateDatasetRequest.d.mts +16 -0
- package/dist/esm/api/resources/datasets/client/requests/UpdateDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/UploadCsvToDatasetRequest.d.mts +14 -0
- package/dist/esm/api/resources/datasets/client/requests/UploadCsvToDatasetRequest.mjs +2 -0
- package/dist/esm/api/resources/datasets/client/requests/index.d.mts +11 -0
- package/dist/esm/api/resources/datasets/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/datasets/exports.d.mts +2 -0
- package/dist/esm/api/resources/datasets/exports.mjs +3 -0
- package/dist/esm/api/resources/datasets/index.d.mts +1 -0
- package/dist/esm/api/resources/datasets/index.mjs +1 -0
- package/dist/esm/api/resources/entities/client/Client.d.mts +164 -0
- package/dist/esm/api/resources/entities/client/Client.mjs +436 -0
- package/dist/esm/api/resources/entities/client/index.d.mts +1 -0
- package/dist/esm/api/resources/entities/client/index.mjs +1 -0
- package/dist/esm/api/resources/entities/client/requests/CreateEntitiesBatchRequest.d.mts +35 -0
- package/dist/esm/api/resources/entities/client/requests/CreateEntitiesBatchRequest.mjs +2 -0
- package/dist/esm/api/resources/entities/client/requests/DeleteEntityRequest.d.mts +10 -0
- package/dist/esm/api/resources/entities/client/requests/DeleteEntityRequest.mjs +2 -0
- package/dist/esm/api/resources/entities/client/requests/GetEntityRequest.d.mts +10 -0
- package/dist/esm/api/resources/entities/client/requests/GetEntityRequest.mjs +2 -0
- package/dist/esm/api/resources/entities/client/requests/ListEntitiesRequest.d.mts +19 -0
- package/dist/esm/api/resources/entities/client/requests/ListEntitiesRequest.mjs +2 -0
- package/dist/esm/api/resources/entities/client/requests/UpdateEntityRequest.d.mts +22 -0
- package/dist/esm/api/resources/entities/client/requests/UpdateEntityRequest.mjs +2 -0
- package/dist/esm/api/resources/entities/client/requests/index.d.mts +5 -0
- package/dist/esm/api/resources/entities/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/entities/exports.d.mts +2 -0
- package/dist/esm/api/resources/entities/exports.mjs +3 -0
- package/dist/esm/api/resources/entities/index.d.mts +1 -0
- package/dist/esm/api/resources/entities/index.mjs +1 -0
- package/dist/esm/api/resources/index.d.mts +4 -0
- package/dist/esm/api/resources/index.mjs +4 -0
- package/dist/esm/api/resources/jobs/client/Client.d.mts +47 -25
- package/dist/esm/api/resources/jobs/client/Client.mjs +136 -64
- package/dist/esm/api/resources/jobs/client/requests/DeleteJobRequest.d.mts +10 -0
- package/dist/esm/api/resources/jobs/client/requests/DeleteJobRequest.mjs +2 -0
- package/dist/esm/api/resources/jobs/client/requests/GetUserJobsRequest.d.mts +5 -0
- package/dist/esm/api/resources/jobs/client/requests/SubmitRequestDto.d.mts +6 -0
- package/dist/esm/api/resources/jobs/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/monitors/client/Client.d.mts +73 -34
- package/dist/esm/api/resources/monitors/client/Client.mjs +207 -77
- package/dist/esm/api/resources/monitors/client/requests/DeleteMonitorRequest.d.mts +10 -0
- package/dist/esm/api/resources/monitors/client/requests/DeleteMonitorRequest.mjs +2 -0
- package/dist/esm/api/resources/monitors/client/requests/GetMonitorStatusHistoryRequest.d.mts +10 -0
- package/dist/esm/api/resources/monitors/client/requests/GetMonitorStatusHistoryRequest.mjs +2 -0
- package/dist/esm/api/resources/monitors/client/requests/ListMonitorsRequest.d.mts +5 -0
- package/dist/esm/api/resources/monitors/client/requests/index.d.mts +2 -0
- package/dist/esm/api/types/AdditionalAttributes.d.mts +7 -0
- package/dist/esm/api/types/AdditionalAttributes.mjs +2 -0
- package/dist/esm/api/types/CompanyAttributes.d.mts +17 -0
- package/dist/esm/api/types/CompanyAttributes.mjs +2 -0
- package/dist/esm/api/types/ConnectedEntity.d.mts +30 -0
- package/dist/esm/api/types/ConnectedEntity.mjs +2 -0
- package/dist/esm/api/types/CreateDatasetCsvResponse.d.mts +10 -0
- package/dist/esm/api/types/CreateDatasetCsvResponse.mjs +2 -0
- package/dist/esm/api/types/CreateEntitiesBatchResponse.d.mts +7 -0
- package/dist/esm/api/types/CreateEntitiesBatchResponse.mjs +2 -0
- package/dist/esm/api/types/CreateEntityRequest.d.mts +13 -0
- package/dist/esm/api/types/CreateEntityRequest.mjs +2 -0
- package/dist/esm/api/types/CreateEntityResponse.d.mts +6 -0
- package/dist/esm/api/types/CreateEntityResponse.mjs +2 -0
- package/dist/esm/api/types/DatasetEntityIdsRequest.d.mts +4 -0
- package/dist/esm/api/types/DatasetEntityIdsRequest.mjs +2 -0
- package/dist/esm/api/types/DatasetEntityListResponse.d.mts +11 -0
- package/dist/esm/api/types/DatasetEntityListResponse.mjs +2 -0
- package/dist/esm/api/types/DatasetListResponse.d.mts +11 -0
- package/dist/esm/api/types/DatasetListResponse.mjs +2 -0
- package/dist/esm/api/types/DatasetResponse.d.mts +20 -0
- package/dist/esm/api/types/DatasetResponse.mjs +2 -0
- package/dist/esm/api/types/DatasetSortBy.d.mts +7 -0
- package/dist/esm/api/types/DatasetSortBy.mjs +7 -0
- package/dist/esm/api/types/DatasetStatus.d.mts +15 -0
- package/dist/esm/api/types/DatasetStatus.mjs +15 -0
- package/dist/esm/api/types/DatasetStatusEntry.d.mts +11 -0
- package/dist/esm/api/types/DatasetStatusEntry.mjs +2 -0
- package/dist/esm/api/types/DatasetStatusHistoryResponse.d.mts +7 -0
- package/dist/esm/api/types/DatasetStatusHistoryResponse.mjs +2 -0
- package/dist/esm/api/types/DeleteJobResponseDto.d.mts +8 -0
- package/dist/esm/api/types/DeleteJobResponseDto.mjs +2 -0
- package/dist/esm/api/types/DeleteMonitorResponseDto.d.mts +8 -0
- package/dist/esm/api/types/DeleteMonitorResponseDto.mjs +2 -0
- package/dist/esm/api/types/EnrichmentType.d.mts +3 -1
- package/dist/esm/api/types/EnrichmentType.mjs +3 -1
- package/dist/esm/api/types/EntityListResponse.d.mts +11 -0
- package/dist/esm/api/types/EntityListResponse.mjs +2 -0
- package/dist/esm/api/types/EntityResponse.d.mts +20 -0
- package/dist/esm/api/types/EntityResponse.mjs +2 -0
- package/dist/esm/api/types/EntitySortBy.d.mts +7 -0
- package/dist/esm/api/types/EntitySortBy.mjs +7 -0
- package/dist/esm/api/types/EntityStatus.d.mts +15 -0
- package/dist/esm/api/types/EntityStatus.mjs +15 -0
- package/dist/esm/api/types/EntitySummary.d.mts +18 -0
- package/dist/esm/api/types/EntitySummary.mjs +2 -0
- package/dist/esm/api/types/EntityType.d.mts +11 -0
- package/dist/esm/api/types/EntityType.mjs +11 -0
- package/dist/esm/api/types/EntityValidationErrorBody.d.mts +16 -0
- package/dist/esm/api/types/EntityValidationErrorBody.mjs +2 -0
- package/dist/esm/api/types/ManageEntitiesResponse.d.mts +6 -0
- package/dist/esm/api/types/ManageEntitiesResponse.mjs +2 -0
- package/dist/esm/api/types/MonitorListItemDto.d.mts +2 -0
- package/dist/esm/api/types/MonitorRecord.d.mts +1 -0
- package/dist/esm/api/types/MonitorStatusEntry.d.mts +68 -0
- package/dist/esm/api/types/MonitorStatusEntry.mjs +24 -0
- package/dist/esm/api/types/MonitorStatusHistoryResponseDto.d.mts +13 -0
- package/dist/esm/api/types/MonitorStatusHistoryResponseDto.mjs +2 -0
- package/dist/esm/api/types/OwnershipFilter.d.mts +14 -0
- package/dist/esm/api/types/OwnershipFilter.mjs +14 -0
- package/dist/esm/api/types/PullJobResponseDto.d.mts +2 -0
- package/dist/esm/api/types/Record_.d.mts +5 -0
- package/dist/esm/api/types/SharingInfo.d.mts +24 -0
- package/dist/esm/api/types/SharingInfo.mjs +10 -0
- package/dist/esm/api/types/SkippedRow.d.mts +13 -0
- package/dist/esm/api/types/SkippedRow.mjs +2 -0
- package/dist/esm/api/types/SortOrder.d.mts +11 -0
- package/dist/esm/api/types/SortOrder.mjs +11 -0
- package/dist/esm/api/types/UploadCsvToDatasetResponse.d.mts +8 -0
- package/dist/esm/api/types/UploadCsvToDatasetResponse.mjs +2 -0
- package/dist/esm/api/types/UserJob.d.mts +3 -0
- package/dist/esm/api/types/ValidationReport.d.mts +17 -0
- package/dist/esm/api/types/ValidationReport.mjs +2 -0
- package/dist/esm/api/types/index.d.mts +33 -0
- package/dist/esm/api/types/index.mjs +33 -0
- package/dist/esm/core/auth/BasicAuth.d.mts +2 -2
- package/dist/esm/core/auth/BasicAuth.mjs +7 -1
- package/dist/esm/core/exports.d.mts +1 -0
- package/dist/esm/core/exports.mjs +1 -0
- package/dist/esm/core/fetcher/Fetcher.d.mts +3 -0
- package/dist/esm/core/fetcher/Fetcher.mjs +11 -1
- package/dist/esm/core/file/exports.d.mts +1 -0
- package/dist/esm/core/file/exports.mjs +1 -0
- package/dist/esm/core/file/file.d.mts +10 -0
- package/dist/esm/core/file/file.mjs +185 -0
- package/dist/esm/core/file/index.d.mts +2 -0
- package/dist/esm/core/file/index.mjs +2 -0
- package/dist/esm/core/file/types.d.mts +66 -0
- package/dist/esm/core/file/types.mjs +1 -0
- package/dist/esm/core/form-data-utils/FormDataWrapper.d.mts +15 -0
- package/dist/esm/core/form-data-utils/FormDataWrapper.mjs +147 -0
- package/dist/esm/core/form-data-utils/encodeAsFormParameter.d.mts +1 -0
- package/dist/esm/core/form-data-utils/encodeAsFormParameter.mjs +9 -0
- package/dist/esm/core/form-data-utils/index.d.mts +2 -0
- package/dist/esm/core/form-data-utils/index.mjs +2 -0
- package/dist/esm/core/index.d.mts +2 -0
- package/dist/esm/core/index.mjs +2 -0
- package/dist/esm/core/url/QueryStringBuilder.d.mts +47 -0
- package/dist/esm/core/url/QueryStringBuilder.mjs +80 -0
- package/dist/esm/core/url/index.d.mts +1 -0
- package/dist/esm/core/url/index.mjs +1 -0
- package/dist/esm/core/url/qs.d.mts +2 -1
- package/dist/esm/core/url/qs.mjs +24 -12
- package/dist/esm/errors/CatchAllApiError.d.mts +3 -1
- package/dist/esm/errors/CatchAllApiError.mjs +4 -1
- package/dist/esm/errors/CatchAllApiTimeoutError.d.mts +4 -1
- package/dist/esm/errors/CatchAllApiTimeoutError.mjs +4 -1
- package/dist/esm/errors/handleNonStatusCodeError.mjs +4 -1
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +29 -7
- package/reference.md +1455 -49
package/README.md
CHANGED
|
@@ -11,8 +11,10 @@ The Newscatcher TypeScript library provides convenient access to the Newscatcher
|
|
|
11
11
|
- [Installation](#installation)
|
|
12
12
|
- [Reference](#reference)
|
|
13
13
|
- [Usage](#usage)
|
|
14
|
+
- [Environments](#environments)
|
|
14
15
|
- [Request and Response Types](#request-and-response-types)
|
|
15
16
|
- [Exception Handling](#exception-handling)
|
|
17
|
+
- [File Uploads](#file-uploads)
|
|
16
18
|
- [Advanced](#advanced)
|
|
17
19
|
- [Subpackage Exports](#subpackage-exports)
|
|
18
20
|
- [Additional Headers](#additional-headers)
|
|
@@ -59,6 +61,18 @@ await client.jobs.createJob({
|
|
|
59
61
|
});
|
|
60
62
|
```
|
|
61
63
|
|
|
64
|
+
## Environments
|
|
65
|
+
|
|
66
|
+
This SDK allows you to configure different environments for API requests.
|
|
67
|
+
|
|
68
|
+
```typescript
|
|
69
|
+
import { CatchAllApiClient, CatchAllApiEnvironment } from "newscatcher-catchall-sdk";
|
|
70
|
+
|
|
71
|
+
const client = new CatchAllApiClient({
|
|
72
|
+
environment: CatchAllApiEnvironment.Default,
|
|
73
|
+
});
|
|
74
|
+
```
|
|
75
|
+
|
|
62
76
|
## Request and Response Types
|
|
63
77
|
|
|
64
78
|
The SDK exports all request and response types as TypeScript interfaces. Simply import them with the
|
|
@@ -67,7 +81,7 @@ following namespace:
|
|
|
67
81
|
```typescript
|
|
68
82
|
import { CatchAllApi } from "newscatcher-catchall-sdk";
|
|
69
83
|
|
|
70
|
-
const request: CatchAllApi.
|
|
84
|
+
const request: CatchAllApi.GetUserJobsRequest = {
|
|
71
85
|
...
|
|
72
86
|
};
|
|
73
87
|
```
|
|
@@ -92,6 +106,51 @@ try {
|
|
|
92
106
|
}
|
|
93
107
|
```
|
|
94
108
|
|
|
109
|
+
## File Uploads
|
|
110
|
+
|
|
111
|
+
You can upload files using the client:
|
|
112
|
+
|
|
113
|
+
```typescript
|
|
114
|
+
import { createReadStream } from "fs";
|
|
115
|
+
import * as fs from "fs";
|
|
116
|
+
import { CatchAllApiClient } from "newscatcher-catchall-sdk";
|
|
117
|
+
|
|
118
|
+
const client = new CatchAllApiClient({ apiKey: "YOUR_API_KEY" });
|
|
119
|
+
await client.datasets.createDatasetFromCsv({
|
|
120
|
+
file: fs.createReadStream("/path/to/your/file"),
|
|
121
|
+
name: "name"
|
|
122
|
+
});
|
|
123
|
+
```
|
|
124
|
+
The client accepts a variety of types for file upload parameters:
|
|
125
|
+
* Stream types: `fs.ReadStream`, `stream.Readable`, and `ReadableStream`
|
|
126
|
+
* Buffered types: `Buffer`, `Blob`, `File`, `ArrayBuffer`, `ArrayBufferView`, and `Uint8Array`
|
|
127
|
+
|
|
128
|
+
### Metadata
|
|
129
|
+
|
|
130
|
+
You can configure metadata when uploading a file:
|
|
131
|
+
```typescript
|
|
132
|
+
const file: Uploadable.WithMetadata = {
|
|
133
|
+
data: createReadStream("path/to/file"),
|
|
134
|
+
filename: "my-file", // optional
|
|
135
|
+
contentType: "audio/mpeg", // optional
|
|
136
|
+
contentLength: 1949, // optional
|
|
137
|
+
};
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
Alternatively, you can upload a file directly from a file path:
|
|
141
|
+
```typescript
|
|
142
|
+
const file : Uploadable.FromPath = {
|
|
143
|
+
path: "path/to/file",
|
|
144
|
+
filename: "my-file", // optional
|
|
145
|
+
contentType: "audio/mpeg", // optional
|
|
146
|
+
contentLength: 1949, // optional
|
|
147
|
+
};
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
The metadata is used to set the `Content-Length`, `Content-Type`, and `Content-Disposition` headers. If not provided, the client will attempt to determine them automatically.
|
|
151
|
+
For example, `fs.ReadStream` has a `path` property which the SDK uses to retrieve the file size from the filesystem without loading it into memory.
|
|
152
|
+
|
|
153
|
+
|
|
95
154
|
## Advanced
|
|
96
155
|
|
|
97
156
|
### Subpackage Exports
|
|
@@ -303,3 +362,5 @@ On the other hand, contributions to the README are always very welcome!
|
|
|
303
362
|
- Documentation: [www.newscatcherapi.com/docs/web-search-api](https://www.newscatcherapi.com/docs/web-search-api/get-started/introduction)
|
|
304
363
|
- Support: <support@newscatcherapi.com>
|
|
305
364
|
|
|
365
|
+
|
|
366
|
+
|
package/dist/cjs/BaseClient.js
CHANGED
|
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
|
|
|
43
43
|
const headers = (0, headers_js_1.mergeHeaders)({
|
|
44
44
|
"X-Fern-Language": "JavaScript",
|
|
45
45
|
"X-Fern-SDK-Name": "newscatcher-catchall-sdk",
|
|
46
|
-
"X-Fern-SDK-Version": "1.
|
|
47
|
-
"User-Agent": "newscatcher-catchall-sdk/1.
|
|
46
|
+
"X-Fern-SDK-Version": "1.5.0",
|
|
47
|
+
"User-Agent": "newscatcher-catchall-sdk/1.5.0",
|
|
48
48
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
49
49
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
50
50
|
}, options === null || options === void 0 ? void 0 : options.headers);
|
package/dist/cjs/Client.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { DatasetsClient } from "./api/resources/datasets/client/Client.js";
|
|
2
|
+
import { EntitiesClient } from "./api/resources/entities/client/Client.js";
|
|
1
3
|
import { JobsClient } from "./api/resources/jobs/client/Client.js";
|
|
2
4
|
import { MetaClient } from "./api/resources/meta/client/Client.js";
|
|
3
5
|
import { MonitorsClient } from "./api/resources/monitors/client/Client.js";
|
|
@@ -13,10 +15,14 @@ export declare class CatchAllApiClient {
|
|
|
13
15
|
protected readonly _options: NormalizedClientOptionsWithAuth<CatchAllApiClient.Options>;
|
|
14
16
|
protected _jobs: JobsClient | undefined;
|
|
15
17
|
protected _monitors: MonitorsClient | undefined;
|
|
18
|
+
protected _entities: EntitiesClient | undefined;
|
|
19
|
+
protected _datasets: DatasetsClient | undefined;
|
|
16
20
|
protected _meta: MetaClient | undefined;
|
|
17
21
|
constructor(options?: CatchAllApiClient.Options);
|
|
18
22
|
get jobs(): JobsClient;
|
|
19
23
|
get monitors(): MonitorsClient;
|
|
24
|
+
get entities(): EntitiesClient;
|
|
25
|
+
get datasets(): DatasetsClient;
|
|
20
26
|
get meta(): MetaClient;
|
|
21
27
|
/**
|
|
22
28
|
* Make a passthrough request using the SDK's configured auth, retry, logging, etc.
|
package/dist/cjs/Client.js
CHANGED
|
@@ -44,9 +44,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
44
44
|
};
|
|
45
45
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
46
|
exports.CatchAllApiClient = void 0;
|
|
47
|
-
const Client_js_1 = require("./api/resources/
|
|
48
|
-
const Client_js_2 = require("./api/resources/
|
|
49
|
-
const Client_js_3 = require("./api/resources/
|
|
47
|
+
const Client_js_1 = require("./api/resources/datasets/client/Client.js");
|
|
48
|
+
const Client_js_2 = require("./api/resources/entities/client/Client.js");
|
|
49
|
+
const Client_js_3 = require("./api/resources/jobs/client/Client.js");
|
|
50
|
+
const Client_js_4 = require("./api/resources/meta/client/Client.js");
|
|
51
|
+
const Client_js_5 = require("./api/resources/monitors/client/Client.js");
|
|
50
52
|
const BaseClient_js_1 = require("./BaseClient.js");
|
|
51
53
|
const core = __importStar(require("./core/index.js"));
|
|
52
54
|
class CatchAllApiClient {
|
|
@@ -55,15 +57,23 @@ class CatchAllApiClient {
|
|
|
55
57
|
}
|
|
56
58
|
get jobs() {
|
|
57
59
|
var _a;
|
|
58
|
-
return ((_a = this._jobs) !== null && _a !== void 0 ? _a : (this._jobs = new
|
|
60
|
+
return ((_a = this._jobs) !== null && _a !== void 0 ? _a : (this._jobs = new Client_js_3.JobsClient(this._options)));
|
|
59
61
|
}
|
|
60
62
|
get monitors() {
|
|
61
63
|
var _a;
|
|
62
|
-
return ((_a = this._monitors) !== null && _a !== void 0 ? _a : (this._monitors = new
|
|
64
|
+
return ((_a = this._monitors) !== null && _a !== void 0 ? _a : (this._monitors = new Client_js_5.MonitorsClient(this._options)));
|
|
65
|
+
}
|
|
66
|
+
get entities() {
|
|
67
|
+
var _a;
|
|
68
|
+
return ((_a = this._entities) !== null && _a !== void 0 ? _a : (this._entities = new Client_js_2.EntitiesClient(this._options)));
|
|
69
|
+
}
|
|
70
|
+
get datasets() {
|
|
71
|
+
var _a;
|
|
72
|
+
return ((_a = this._datasets) !== null && _a !== void 0 ? _a : (this._datasets = new Client_js_1.DatasetsClient(this._options)));
|
|
63
73
|
}
|
|
64
74
|
get meta() {
|
|
65
75
|
var _a;
|
|
66
|
-
return ((_a = this._meta) !== null && _a !== void 0 ? _a : (this._meta = new
|
|
76
|
+
return ((_a = this._meta) !== null && _a !== void 0 ? _a : (this._meta = new Client_js_4.MetaClient(this._options)));
|
|
67
77
|
}
|
|
68
78
|
/**
|
|
69
79
|
* Make a passthrough request using the SDK's configured auth, retry, logging, etc.
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import type * as core from "../../core/index.js";
|
|
2
2
|
import * as errors from "../../errors/index.js";
|
|
3
|
-
import type * as CatchAllApi from "../index.js";
|
|
4
3
|
export declare class BadRequestError extends errors.CatchAllApiError {
|
|
5
|
-
constructor(body
|
|
4
|
+
constructor(body?: unknown, rawResponse?: core.RawResponse);
|
|
6
5
|
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type * as core from "../../core/index.js";
|
|
2
|
+
import * as errors from "../../errors/index.js";
|
|
3
|
+
import type * as CatchAllApi from "../index.js";
|
|
4
|
+
export declare class UnauthorizedError extends errors.CatchAllApiError {
|
|
5
|
+
constructor(body: CatchAllApi.Error_, rawResponse?: core.RawResponse);
|
|
6
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
exports.UnauthorizedError = void 0;
|
|
38
|
+
const errors = __importStar(require("../../errors/index.js"));
|
|
39
|
+
class UnauthorizedError extends errors.CatchAllApiError {
|
|
40
|
+
constructor(body, rawResponse) {
|
|
41
|
+
super({
|
|
42
|
+
message: "UnauthorizedError",
|
|
43
|
+
statusCode: 401,
|
|
44
|
+
body: body,
|
|
45
|
+
rawResponse: rawResponse,
|
|
46
|
+
});
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
exports.UnauthorizedError = UnauthorizedError;
|
|
@@ -17,4 +17,5 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
17
17
|
__exportStar(require("./BadRequestError.js"), exports);
|
|
18
18
|
__exportStar(require("./ForbiddenError.js"), exports);
|
|
19
19
|
__exportStar(require("./NotFoundError.js"), exports);
|
|
20
|
+
__exportStar(require("./UnauthorizedError.js"), exports);
|
|
20
21
|
__exportStar(require("./UnprocessableEntityError.js"), exports);
|
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
3
|
+
import * as core from "../../../../core/index.js";
|
|
4
|
+
import * as CatchAllApi from "../../../index.js";
|
|
5
|
+
export declare namespace DatasetsClient {
|
|
6
|
+
type Options = BaseClientOptions;
|
|
7
|
+
interface RequestOptions extends BaseRequestOptions {
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Operations to create and manage datasets of entities.
|
|
12
|
+
*
|
|
13
|
+
* A dataset is a named collection of entities — think of it as a watchlist or
|
|
14
|
+
* portfolio. Connect a dataset to a job via `connected_dataset_ids` to activate
|
|
15
|
+
* Company Watchlist. Datasets can be reused across multiple jobs and monitors.
|
|
16
|
+
*/
|
|
17
|
+
export declare class DatasetsClient {
|
|
18
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<DatasetsClient.Options>;
|
|
19
|
+
constructor(options?: DatasetsClient.Options);
|
|
20
|
+
/**
|
|
21
|
+
* Returns a paginated list of datasets belonging to the authenticated
|
|
22
|
+
* organization. Supports filtering by status and sorting by name,
|
|
23
|
+
* status, or creation date.
|
|
24
|
+
*
|
|
25
|
+
* @param {CatchAllApi.ListDatasetsRequest} request
|
|
26
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
27
|
+
*
|
|
28
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
29
|
+
*
|
|
30
|
+
* @example
|
|
31
|
+
* await client.datasets.listDatasets({
|
|
32
|
+
* search: "Portfolio"
|
|
33
|
+
* })
|
|
34
|
+
*/
|
|
35
|
+
listDatasets(request?: CatchAllApi.ListDatasetsRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.DatasetListResponse>;
|
|
36
|
+
private __listDatasets;
|
|
37
|
+
/**
|
|
38
|
+
* Creates a new dataset from a list of existing entity IDs.
|
|
39
|
+
*
|
|
40
|
+
* If any of the provided entity IDs do not exist or do not belong to
|
|
41
|
+
* your organization, the request fails with `400`. All entity IDs must
|
|
42
|
+
* be valid before the dataset is created.
|
|
43
|
+
*
|
|
44
|
+
* To create a dataset and entities in one step, use the [`Create dataset from CSV`](https://www.newscatcherapi.com/docs/web-search-api/api-reference/datasets/create-dataset-from-csv)
|
|
45
|
+
* endpoint instead.
|
|
46
|
+
*
|
|
47
|
+
* @param {CatchAllApi.CreateDatasetRequest} request
|
|
48
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
49
|
+
*
|
|
50
|
+
* @throws {@link CatchAllApi.BadRequestError}
|
|
51
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
52
|
+
* @throws {@link CatchAllApi.UnprocessableEntityError}
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* await client.datasets.createDataset({
|
|
56
|
+
* name: "My Portfolio",
|
|
57
|
+
* description: "Companies in our investment portfolio",
|
|
58
|
+
* entity_ids: ["854198fa-f702-49db-a381-0427fa87f173", "a1b2c3d4-e5f6-7890-abcd-ef1234567890"]
|
|
59
|
+
* })
|
|
60
|
+
*/
|
|
61
|
+
createDataset(request: CatchAllApi.CreateDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.DatasetResponse>;
|
|
62
|
+
private __createDataset;
|
|
63
|
+
/**
|
|
64
|
+
* Creates a new dataset by uploading a CSV file. Each row in the CSV
|
|
65
|
+
* becomes an entity. The `name` column is required; all other columns
|
|
66
|
+
* are optional.
|
|
67
|
+
*
|
|
68
|
+
* **CSV format:**
|
|
69
|
+
* ```csv
|
|
70
|
+
* name,description,domain,alternative_names,key_persons
|
|
71
|
+
* NewsCatcher,"AI-powered news data provider",newscatcherapi.com,"NC;NewsCatcher API","Artem Bugara;Maksym Sugonyaka"
|
|
72
|
+
* OpenAI,"Artificial intelligence research company",openai.com,"Open AI","Sam Altman"
|
|
73
|
+
* ```
|
|
74
|
+
*
|
|
75
|
+
* Use semicolons (`;`) to separate multiple values in `alternative_names` and `key_persons`. Rows with empty `name` are skipped and reported in `validation_report`.
|
|
76
|
+
*
|
|
77
|
+
* **Note**: The response shape differs from the JSON dataset creation endpoint: it returns `dataset_id` (not `id`) and includes a `validation_report` with details on skipped rows.
|
|
78
|
+
*
|
|
79
|
+
* @param {CatchAllApi.CreateDatasetFromCsvRequest} request
|
|
80
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
81
|
+
*
|
|
82
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
83
|
+
* @throws {@link CatchAllApi.UnprocessableEntityError}
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* import { createReadStream } from "fs";
|
|
87
|
+
* await client.datasets.createDatasetFromCsv({
|
|
88
|
+
* file: fs.createReadStream("/path/to/your/file"),
|
|
89
|
+
* name: "name"
|
|
90
|
+
* })
|
|
91
|
+
*/
|
|
92
|
+
createDatasetFromCsv(request: CatchAllApi.CreateDatasetFromCsvRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.CreateDatasetCsvResponse>;
|
|
93
|
+
private __createDatasetFromCsv;
|
|
94
|
+
/**
|
|
95
|
+
* Returns a single dataset by ID including entity count and current status.
|
|
96
|
+
*
|
|
97
|
+
* @param {CatchAllApi.GetDatasetRequest} request
|
|
98
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
99
|
+
*
|
|
100
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
101
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
102
|
+
*
|
|
103
|
+
* @example
|
|
104
|
+
* await client.datasets.getDataset({
|
|
105
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2"
|
|
106
|
+
* })
|
|
107
|
+
*/
|
|
108
|
+
getDataset(request: CatchAllApi.GetDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.DatasetResponse>;
|
|
109
|
+
private __getDataset;
|
|
110
|
+
/**
|
|
111
|
+
* Permanently deletes a dataset. The entities within the dataset are
|
|
112
|
+
* not deleted — only the dataset itself. This operation cannot be
|
|
113
|
+
* undone.
|
|
114
|
+
*
|
|
115
|
+
* @param {CatchAllApi.DeleteDatasetRequest} request
|
|
116
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
117
|
+
*
|
|
118
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
119
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
120
|
+
*
|
|
121
|
+
* @example
|
|
122
|
+
* await client.datasets.deleteDataset({
|
|
123
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2"
|
|
124
|
+
* })
|
|
125
|
+
*/
|
|
126
|
+
deleteDataset(request: CatchAllApi.DeleteDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<void>;
|
|
127
|
+
private __deleteDataset;
|
|
128
|
+
/**
|
|
129
|
+
* Updates the name or description of a dataset.
|
|
130
|
+
*
|
|
131
|
+
* @param {CatchAllApi.UpdateDatasetRequest} request
|
|
132
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
133
|
+
*
|
|
134
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
135
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
136
|
+
* @throws {@link CatchAllApi.UnprocessableEntityError}
|
|
137
|
+
*
|
|
138
|
+
* @example
|
|
139
|
+
* await client.datasets.updateDataset({
|
|
140
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2",
|
|
141
|
+
* name: "My Portfolio (updated)",
|
|
142
|
+
* description: "Updated Q1 2026 watchlist"
|
|
143
|
+
* })
|
|
144
|
+
*/
|
|
145
|
+
updateDataset(request: CatchAllApi.UpdateDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.DatasetResponse>;
|
|
146
|
+
private __updateDataset;
|
|
147
|
+
/**
|
|
148
|
+
* Returns a paginated list of entities in a dataset. Supports filtering by status and entity type.
|
|
149
|
+
*
|
|
150
|
+
* @param {CatchAllApi.ListEntitiesInDatasetRequest} request
|
|
151
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
152
|
+
*
|
|
153
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
154
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
155
|
+
*
|
|
156
|
+
* @example
|
|
157
|
+
* await client.datasets.listEntitiesInDataset({
|
|
158
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2"
|
|
159
|
+
* })
|
|
160
|
+
*/
|
|
161
|
+
listEntitiesInDataset(request: CatchAllApi.ListEntitiesInDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.DatasetEntityListResponse>;
|
|
162
|
+
private __listEntitiesInDataset;
|
|
163
|
+
/**
|
|
164
|
+
* Adds one or more existing entities to a dataset. Returns the number of entities added.
|
|
165
|
+
*
|
|
166
|
+
* @param {CatchAllApi.AddEntitiesToDatasetRequest} request
|
|
167
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
168
|
+
*
|
|
169
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
170
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
171
|
+
* @throws {@link CatchAllApi.UnprocessableEntityError}
|
|
172
|
+
*
|
|
173
|
+
* @example
|
|
174
|
+
* await client.datasets.addEntitiesToDataset({
|
|
175
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2",
|
|
176
|
+
* body: {
|
|
177
|
+
* entity_ids: ["854198fa-f702-49db-a381-0427fa87f173"]
|
|
178
|
+
* }
|
|
179
|
+
* })
|
|
180
|
+
*/
|
|
181
|
+
addEntitiesToDataset(request: CatchAllApi.AddEntitiesToDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.ManageEntitiesResponse>;
|
|
182
|
+
private __addEntitiesToDataset;
|
|
183
|
+
/**
|
|
184
|
+
* Removes one or more entities from a dataset. The entities themselves
|
|
185
|
+
* are not deleted — they are only removed from this dataset. Returns
|
|
186
|
+
* the number of entities removed.
|
|
187
|
+
*
|
|
188
|
+
* @param {CatchAllApi.RemoveEntitiesFromDatasetRequest} request
|
|
189
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
190
|
+
*
|
|
191
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
192
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
193
|
+
* @throws {@link CatchAllApi.UnprocessableEntityError}
|
|
194
|
+
*
|
|
195
|
+
* @example
|
|
196
|
+
* await client.datasets.removeEntitiesFromDataset({
|
|
197
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2",
|
|
198
|
+
* body: {
|
|
199
|
+
* entity_ids: ["854198fa-f702-49db-a381-0427fa87f173"]
|
|
200
|
+
* }
|
|
201
|
+
* })
|
|
202
|
+
*/
|
|
203
|
+
removeEntitiesFromDataset(request: CatchAllApi.RemoveEntitiesFromDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.ManageEntitiesResponse>;
|
|
204
|
+
private __removeEntitiesFromDataset;
|
|
205
|
+
/**
|
|
206
|
+
* Returns the full status change history for a dataset, ordered
|
|
207
|
+
* chronologically from oldest to newest.
|
|
208
|
+
*
|
|
209
|
+
* @param {CatchAllApi.GetDatasetStatusHistoryRequest} request
|
|
210
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
211
|
+
*
|
|
212
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
213
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
214
|
+
*
|
|
215
|
+
* @example
|
|
216
|
+
* await client.datasets.getDatasetStatusHistory({
|
|
217
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2"
|
|
218
|
+
* })
|
|
219
|
+
*/
|
|
220
|
+
getDatasetStatusHistory(request: CatchAllApi.GetDatasetStatusHistoryRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.DatasetStatusHistoryResponse>;
|
|
221
|
+
private __getDatasetStatusHistory;
|
|
222
|
+
/**
|
|
223
|
+
* Appends new companies to an existing dataset by uploading a CSV file.
|
|
224
|
+
* Uses the same CSV format as the dataset creation endpoint.
|
|
225
|
+
*
|
|
226
|
+
* The response omits `dataset_name` compared to the create-from-CSV
|
|
227
|
+
* endpoint since the dataset already exists.
|
|
228
|
+
*
|
|
229
|
+
* @param {CatchAllApi.UploadCsvToDatasetRequest} request
|
|
230
|
+
* @param {DatasetsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
231
|
+
*
|
|
232
|
+
* @throws {@link CatchAllApi.ForbiddenError}
|
|
233
|
+
* @throws {@link CatchAllApi.NotFoundError}
|
|
234
|
+
* @throws {@link CatchAllApi.UnprocessableEntityError}
|
|
235
|
+
*
|
|
236
|
+
* @example
|
|
237
|
+
* import { createReadStream } from "fs";
|
|
238
|
+
* await client.datasets.uploadCsvToDataset({
|
|
239
|
+
* file: fs.createReadStream("/path/to/your/file"),
|
|
240
|
+
* dataset_id: "ccabb755-afc2-4047-b84c-78d1f23d49b2"
|
|
241
|
+
* })
|
|
242
|
+
*/
|
|
243
|
+
uploadCsvToDataset(request: CatchAllApi.UploadCsvToDatasetRequest, requestOptions?: DatasetsClient.RequestOptions): core.HttpResponsePromise<CatchAllApi.UploadCsvToDatasetResponse>;
|
|
244
|
+
private __uploadCsvToDataset;
|
|
245
|
+
}
|