Type alias FindByIdWithChildrenResult<DocumentType>

FindByIdWithChildrenResult<DocumentType>: {
    children: {
        [collection: string]: DocumentWithId[];
    };
    nextToken?: Key;
    root?: DocumentType;
}

Type Parameters

Type declaration

  • children: {
        [collection: string]: DocumentWithId[];
    }

    The child objects, organised by collection names.

    Similar to the root object, you must check each page of results for children, which will come back based on index order and scan direction.

    NOTE: These are typed as DocumentWithId: you will need to typecast each of the child collections based on the name you specify

  • Optional nextToken?: Key

    The pagination token. If this is not blank, you need to call findByIdWithChildren with this value to get the next page of results.

  • Optional root?: DocumentType

    The root object.

    It may be blank if it is not in the current set of results (this depends on how objects are organised on your index, or if the root object exists at all). If your result is paginated (i.e. there is a nextToken), it is important to continue calling findByIdWithChildren with the previous nextToken and keep checking root on each set of results.

Generated using TypeDoc