-
Notifications
You must be signed in to change notification settings - Fork 11.5k
Closed
Labels
apiarea: API, enterprise API, access token, OAutharea: API, enterprise API, access token, OAuthevent-typesarea: event types, event-typesarea: event types, event-typesplatformAnything related to our platform planAnything related to our platform plan
Description
Problem
If we create event type X and then try to copy paste response as body for Y there are errors related to booking fields and offset:
https://calcominc.slack.com/archives/C08A5QYSTJ6/p1746967955511829
Solution
- Update booking-fields.input.ts to allow passing location default booking field - users can only specify label. In create-event-type.input.ts and update-event-type.input.ts allow passing
offsetStart0 because that is the default value and should be valid.- Since we have location field input - update booking-fields.ts to transform it and then input-event-types.service.ts to use custom location field and if no location field is passed have a default one like with other booking fields.
- Return location default booking field label in booking-fields.ts and then reflect that in output type booking-fields.output.ts.
- Add a test in event-types.controller.e2e-spec.ts to test that if we create event type X and then take its response as body for creating event type Y but with new slug and name that the response of Y matches X successfully.
Bonus
Refactor platform libraries yarn publish to yarn publish-npm so pre-publish and post-publish steps run one after another.
Metadata
Metadata
Assignees
Labels
apiarea: API, enterprise API, access token, OAutharea: API, enterprise API, access token, OAuthevent-typesarea: event types, event-typesarea: event types, event-typesplatformAnything related to our platform planAnything related to our platform plan