import { freezeSys , toPlainObject } from 'contentful-sdk-core' ; import copy from 'fast-copy' ; import { DefaultElements , MakeRequest , MetaSysProps } from '../common-types' ; import { wrapCollection } from '../common-utils' ; import enhanceWithMethods from '../enhance-with-methods' ; export type PreviewApiKeyProps = { sys : MetaSysProps ; name : string ; description : string ; accessToken : string ; } ; export interface PreviewApiKey extends PreviewApiKeyProps , DefaultElements < PreviewApiKeyProps > { } private function createPreviewApiKeyApi ( ) { return { } ; } private param makeRequest param data return export function wrapPreviewApiKey ( _makeRequest , data ) { const previewApiKey = toPlainObject ( copy ( data ) ) ; const previewApiKeyWithMethods = enhanceWithMethods ( previewApiKey , createPreviewApiKeyApi ( ) ) ; return freezeSys ( previewApiKeyWithMethods ) ; } private export const wrapPreviewApiKeyCollection = wrapCollection ( wrapPreviewApiKey ) ;