diff --git a/src/Extracting/ParamHelpers.php b/src/Extracting/ParamHelpers.php index a8125bab..1b7966a8 100644 --- a/src/Extracting/ParamHelpers.php +++ b/src/Extracting/ParamHelpers.php @@ -95,6 +95,7 @@ protected function getDummyValueGenerator(string $type, array $hints = []): \Clo return $max ? $faker->numberBetween((int)$min, (int)$max) : $faker->randomFloat(); }, 'boolean' => fn() => $faker->boolean(), + 'uuid' => fn() => $faker->uuid(), 'string' => fn() => $size ? $faker->lexify(str_repeat("?", $size)) : $faker->word(), 'object' => fn() => [], 'file' => fn() => UploadedFile::fake()->create('test.jpg')->size($size ?: 10), diff --git a/src/Extracting/Strategies/UrlParameters/GetFromUrlParamTag.php b/src/Extracting/Strategies/UrlParameters/GetFromUrlParamTag.php index 48cb5714..155f93d0 100644 --- a/src/Extracting/Strategies/UrlParameters/GetFromUrlParamTag.php +++ b/src/Extracting/Strategies/UrlParameters/GetFromUrlParamTag.php @@ -18,7 +18,7 @@ protected function parseTag(string $tagContent): array // @urlParam user_id The ID of the user. // We match on all the possible types for URL parameters. It's a limited range, so no biggie. - preg_match('/(\w+?)\s+((int|integer|string|float|double|number)\s+)?(required\s+)?([\s\S]*)/', $tagContent, $content); + preg_match('/(\w+?)\s+((int|integer|string|float|double|number|uuid)\s+)?(required\s+)?([\s\S]*)/', $tagContent, $content); if (empty($content)) { // This means only name was supplied $name = $tagContent;