feat(core): Simplify pagination in declarative node design (#5161)

* feat(core): Add pagination to declarative node design

*  Actually make it work

*  Remove rootProperty

*  Fix typo

*  Add support to overwrite url

---------

Co-authored-by: Omar Ajoue <krynble@gmail.com>
This commit is contained in:
Jan Oberhauser
2023-02-01 08:26:13 -06:00
committed by GitHub
parent b27a60b665
commit 87ceb6f4b8
2 changed files with 117 additions and 26 deletions

View File

@@ -185,6 +185,7 @@ export interface IRequestOptionsSimplifiedAuth {
body?: IDataObject;
headers?: IDataObject;
qs?: IDataObject;
url?: string;
skipSslCertificateValidation?: boolean | string;
}
@@ -529,6 +530,7 @@ export interface IN8nHttpFullResponse {
export interface IN8nRequestOperations {
pagination?:
| IN8nRequestOperationPaginationGeneric
| IN8nRequestOperationPaginationOffset
| ((
this: IExecutePaginationFunctions,
@@ -539,7 +541,15 @@ export interface IN8nRequestOperations {
export interface IN8nRequestOperationPaginationBase {
type: string;
properties: {
[key: string]: string | number;
[key: string]: unknown;
};
}
export interface IN8nRequestOperationPaginationGeneric extends IN8nRequestOperationPaginationBase {
type: 'generic';
properties: {
continue: boolean | string;
request: IRequestOptionsSimplifiedAuth;
};
}