Commit Graph

162 Commits

Author SHA1 Message Date
Aswath S
c53e891c8a
fix: refactor booking details api middleware to use team member booking join (#12695)
* refactor booking details api middleware to use team member booking join

Signed-off-by: titanventura <aswath7862001@gmail.com>

* fix. security issue in previous commit. check for booking against current user. then check for team booking

Signed-off-by: titanventura <aswath7862001@gmail.com>

---------

Signed-off-by: titanventura <aswath7862001@gmail.com>
2023-12-07 22:43:51 +00:00
Syed Ali Shahbaz
adf012643a
fix: '/slots' endpoint API fixes (#12693) 2023-12-06 10:10:25 -07:00
Haran Rajkumar
2f4b1818d0
feat: Allow only first slot to be booked (#12636)
Co-authored-by: Morgan Vernay <morgan@cal.com>
2023-12-02 19:07:06 -05:00
Matt Nicolls
d3ddbf418f
fix: fetch event type with a team permissions (#12448)
Co-authored-by: Omar López <zomars@me.com>
2023-11-27 23:14:59 -07:00
Shashank Kaul
b26e688950
fix(api): Added correct include for GET /teams/{teamId}/event-types (#12459)
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2023-11-27 16:44:13 +00:00
Morgan
ca5dd4626d
fix: event-types post api endpoint not showing hosts in response data (#12550) 2023-11-27 12:35:39 +02:00
Syed Ali Shahbaz
16c5b070b6
fix: Admin Logic for event-type API endpoint (#12482)
* Fix Admin logic

* chore: fix prettier

---------

Co-authored-by: Udit Takkar <udit222001@gmail.com>
2023-11-22 06:46:03 -03:00
Alex van Andel
8e7785ca64
fix: Better error reporting & some fixes to deleteUser API (#12439) 2023-11-20 13:28:25 +00:00
Morgan
9029c5b4c4
fix: change api root statusCode to 200 (#12362) 2023-11-16 16:50:43 +00:00
Udit Takkar
371a0f7245
feat: booking errors logging (#12325)
Fixes: https://github.com/calcom/cal.com/issues/12297
Fixes https://github.com/calcom/cal.com/issues/11234

- Displaying error message and X-Vercel-Id( Unique Request Id ) to user on book event form
- Improve error logging 
- Add Error codes

Few things to discuss

1) How to handle calendar integration failures ?
   Currently if for example google integration is broken and someone is trying to book that person then we log the error but don't inform the user that the google calendar is broken and the meeting goes through.
   
 Should I throw error when integration is broken ?
   
<img width="758" alt="Screenshot 2023-11-12 at 12 52 36 AM" src="https://github.com/calcom/cal.com/assets/53316345/c4d921c4-9c8a-4b9b-82a2-bbe0fdbcb3d4">

   
2)  How to handle conferencing app failures? 
 We just default to Cal Video  as location if we are unable to generated conferencing url and log the error and not inform the user(organizer).
2023-11-15 12:52:19 -07:00
Ash Davis
0981c4cb23
feat: POST/PATCH availabilities API to accept date field (#12238) 2023-11-14 21:49:27 -03:00
Morgan
00df493623
revert: "fix: create prisma client singleton with immediately invoked function" (#12366) 2023-11-14 20:22:35 +00:00
Keith Williams
5ab0b85e52
chore: Reduce slots API serverless memory configuration (#12270)
* chore: Reduce API serverless memory configuration

* Only limit to slots for now

* Moved the vercel.json file to root

* More fun with vercel.json files

* Trying new pattern

* Using a pattern that matches the Vercel deployment summary function name

* Trying to set the memory directly in the handler file

* Trying it on all functions

* Changed glob

* Moved vercel.json file to root

* Trying a new glob

* Give me all functions

* Trying just * for all functions

* Trying again...

* Putting the config on the defaultResponder

* Seeing if web app takes setings

* Changed .js to .ts

* Changed root path

* Added back vercel.json now that the path is changed

* Reduced API slots memory to 512

* Removed unneeded code changes'

* Update defaultResponder.ts
2023-11-13 15:37:26 +00:00
Hariom Balhara
e4abc85382
fix: Fix recurring booking failure due to rate limiting (#12322)
Co-authored-by: Keith Williams <keithwillcode@gmail.com>
2023-11-10 20:06:52 +00:00
Morgan
e695f75113
fix: create prisma client singleton with immediately invoked function (#12267) 2023-11-09 12:00:19 -03:00
Keith Williams
2e3b3257db
feat: Add Sentry (#12155)
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2023-11-07 13:18:25 -03:00
Morgan
367c8a96d8
feat: Add user's avatar to POST and PATCH requests in users endpoints (#11187) (#12256)
Co-authored-by: Syed Ali Shahbaz <52925846+alishaz-polymath@users.noreply.github.com>
Co-authored-by: Peer Richelsen <peeroke@gmail.com>

## What does this PR do?

<!-- Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. -->

Fix wrong import introduced in this pr: #11187

<!-- Please provide a loom video for visual changes to speed up reviews
 Loom Video: https://www.loom.com/
-->

## Requirement/Documentation

<!-- Please provide all documents that are important to understand the reason of that PR. -->

- If there is a requirement document, please, share it here.
- If there is ab UI/UX design document, please, share it here.

## Type of change

<!-- Please delete bullets that are not relevant. -->

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] Chore (refactoring code, technical debt, workflow improvements)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update

## How should this be tested?

<!-- Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration. Write details that help to start the tests -->

- Are there environment variables that should be set?
- What are the minimal test data to have?
- What is expected (happy path) to have (input and output)?
- Any other important info that could help to test that PR

## Mandatory Tasks

- [ ] Make sure you have self-reviewed the code. A decent size PR without self-review might be rejected.

## Checklist

<!-- Remove bullet points below that don't apply to you -->

- I haven't read the [contributing guide](https://github.com/calcom/cal.com/blob/main/CONTRIBUTING.md)
- My code doesn't follow the style guidelines of this project
- I haven't commented my code, particularly in hard-to-understand areas
- I haven't checked if my PR needs changes to the documentation
- I haven't checked if my changes generate no new warnings
- I haven't added tests that prove my fix is effective or that my feature works
- I haven't checked if new and existing unit tests pass locally with my changes
2023-11-07 10:21:20 +00:00
Hamza Fouad
e94c030c45
feat: Add user's avatar to POST and PATCH requests in users endpoints (#11187)
Co-authored-by: Syed Ali Shahbaz <52925846+alishaz-polymath@users.noreply.github.com>
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2023-11-07 08:06:52 +00:00
Morgan
6d0c7e4214
chore: init infra folder with dockerized api (#12243)
* chore(infra): scripts and dockerfile for api

* chore(infra): basic readme file

---------

Co-authored-by: Keith Williams <keithwillcode@gmail.com>
2023-11-07 09:47:06 +02:00
Rahul Roy
dff89a4df8
feat: #11922 Removed error for cancelling past time slots (#12126)
Co-authored-by: Rahul Roy <rahulro@maqsoftware.com>
2023-11-03 11:29:41 +00:00
Syed Ali Shahbaz
ed04062540
fix: API to return hosts on event types response (#12204) 2023-11-03 11:28:16 +00:00
Syed Ali Shahbaz
d4d96eb5cd
fix admin check (#12175) 2023-11-02 12:29:15 +00:00
Syed Ali Shahbaz
199d3e4c3f
fix: Auto-link credentials internally on destination calendar (#12055)
Co-authored-by: Morgan <33722304+ThyMinimalDev@users.noreply.github.com>
2023-10-31 13:54:09 -03:00
Syed Ali Shahbaz
ce64c494f4
fix: Allow passing secret for the webhooks via API (#12039) 2023-10-23 10:18:18 -03:00
Syed Ali Shahbaz
4b818de0c8
feat: Allow hideBranding via public API (#11978) 2023-10-19 10:31:13 -03:00
Alex van Andel
73e16215bd
chore: Decouple API from tRPC handlers (#11947) 2023-10-17 15:37:04 +01:00
Syed Ali Shahbaz
2756dff735
fix: Adds mandatory credentiaId in Destination Calendar API endpoint POST (#11880) 2023-10-16 17:09:22 -07:00
sean-brydon
bc81f659aa
test: Tests the order of middleware in API (#11852)
Co-authored-by: Keith Williams <keithwillcode@gmail.com>
2023-10-16 10:00:34 -03:00
Syed Ali Shahbaz
a87d82fd47
chore: Refactors Destination calendar API endpoint with a bunch of fixes (#11789)
Co-authored-by: Omar López <zomars@me.com>
2023-10-12 13:53:48 -07:00
Omar López
208d040f6f
fix: added missing prisma imports (#11867) 2023-10-12 13:22:20 -07:00
sean-brydon
dc9a4f0dba
feat: Add rate limting to API (#11783) 2023-10-11 23:44:00 +01:00
sean-brydon
ce532e0ff6
test: api-middleware (#11825)
* tests/api-middleware

* Skip if true

* Remove prisma from response mock
2023-10-11 15:09:13 +01:00
DexterStorey
303073822c
hotfix for #11626 (#11807) 2023-10-10 21:27:16 +00:00
zomars
a53ea33168 fix: API build 2023-10-09 19:55:54 -07:00
Keith Williams
8a8d284113
fix: API cold boot issues (#11740) 2023-10-06 19:17:07 +01:00
Syed Ali Shahbaz
49b0f48be0
feat: add parentid eventtype API along with children eventTypeIds (#11714)
* add parentId

* Allow POST parentId

* adds eventtypeid of children

* add doc

* adds userId in children

* adds validations

* adds docstring

* fix status codes

* check fix for owners
2023-10-06 13:58:51 +00:00
Aldrin
3e08c66888
refactor: Use template literal instead of '+' operator (#11444)
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
Co-authored-by: zomars <zomars@me.com>
2023-10-03 11:52:19 -07:00
Syed Ali Shahbaz
a3a49f9069
add team availability doc (#11554) 2023-09-27 15:46:07 +04:00
Omar López
560ec244e8
feat: Setups prisma accelerate (#11324) 2023-09-19 21:02:57 +00:00
Kevin Crimi
d9c3c184c4
fix: Return all responses in booking api (#11284) 2023-09-18 16:39:25 -07:00
Shubham Singh
9c3cbee363
feat: preference to show/hide available seats count in events (#11109)
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2023-09-08 11:37:26 -04:00
zomars
b6dea9c161 Sync packages 2023-08-31 12:57:59 -07:00
Syed Ali Shahbaz
3223beb9ac
omit id as it is autocreated, should not be req (#10982) 2023-08-28 06:57:01 +00:00
Omar López
6ce4122528
fix: allows patching booking and period limits from API (#10935) 2023-08-25 14:29:04 +01:00
Syed Ali Shahbaz
7ddbcfcdcf
feat: Adds filter-by-email on /users/_get endpoint for admin calls (#10928)
* adds filter by email on users get for admins

* swagger update

* Update apps/api/pages/api/users/_get.ts

Co-authored-by: Omar López <zomars@me.com>

* .parse is required, also fixed some other issues

---------

Co-authored-by: Omar López <zomars@me.com>
Co-authored-by: Alex van Andel <me@alexvanandel.com>
2023-08-25 14:15:13 +01:00
zomars
0cbf525a78 fix: Disables es-419 until translated 2023-08-22 12:01:50 -07:00
Syed Ali Shahbaz
efa195059e
feat: Add scheduleId to POST and PATCH requests in event-type endpoint (#10816)
* adds scheduleId to PATCH

* adds scheduleID to POST

* updated docs
2023-08-17 15:42:29 +00:00
Alex van Andel
3cab37ed8d
feat: api return schedule (#10769)
Co-authored-by: Leo Giovanetti <hello@leog.me>
Co-authored-by: Omar López <zomars@me.com>
2023-08-15 19:18:25 +00:00
zomars
8071016848 chore: prettier 2023-08-15 11:59:16 -07:00
Leo Giovanetti
a153f9627d
chore: Relying on CALCOM_ENV (#10098)
* Relying on CALCOM_ENV

* Restoring unneeded changes

* Relyon more on IS_PRODUCTION

* Relyon more on IS_PRODUCTION
2023-08-10 12:32:20 -04:00