Closed nileshdev0707 closed 1 year ago
TypeError: Cannot read properties of undefined (reading 'schema')
i am getting this error this is my yml file
org: appsh app: backend service: graphQlApi plugins: - serverless-appsync-plugin environment: SHIPMENTS_TABLE: shipmentsfff provider: name: aws runtime: nodejs16.x custom: appSync: name: app-graphql schema: - 'schema.graphql' authenticationType: AMAZON_COGNITO_USER_POOLS caching: behavior: FULL_REQUEST_CACHING # or PER_RESOLVER_CACHING. Required ttl: 3600 type: 'T2_SMALL' userPoolConfig: defaultAction: ALLOW userPoolId: sdsadsadsadsadTest dataSources: - type: AMAZON_DYNAMODB name: app-datasource config: tableName: ss_tavv pipelineFunctions: ListShipmentsFunction: dataSource: app-datasource code: listShipments.js mappingTemplates: - dataSource: app-datasource type: Query field: listApp functions: # array of functions if kind === 'PIPELINE' - ListShipmentsFunction
listApp(filter: TableShipmentsDevFilterInput, limit: Int, nextToken: String): ShipmentsDevConnection type ShipmentsDev { company_id: String primaryKey: ID sortKey: String } ...........
@nileshdev0707 for the v2+ of serverless-appsync-plugin you don't need custom property.
custom
In your serverless.yml:
# use this ... appSync: ... # instead of this ... custom: appSync: ...
TypeError: Cannot read properties of undefined (reading 'schema')
i am getting this error this is my yml file
schema.graphql` on the root