Skip to content

Commit 3c5a4d2

Browse files
authored
Merge pull request #26 from valpackett/master
Spec fixes
2 parents a23a5cc + c63606a commit 3c5a4d2

File tree

3,367 files changed

+160576
-257636
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,367 files changed

+160576
-257636
lines changed

.github/workflows/compare.yaml

+3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
name: Compare spec to docs
22
on:
33
workflow_dispatch:
4+
pull_request:
5+
push:
6+
branches: [master]
47
jobs:
58
compare:
69
runs-on: ubuntu-22.04

_docmatch/src/docmatch.py

+20-1
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,24 @@ def compare_schema(location, l_name, l, r_name, r):
188188
print(f"** ! unresolved/unnamed param in spec: {p}")
189189
continue
190190
spec_params[p['name']] = p
191+
spec_frm_sch = scm.get('requestBody', {}).get('content', {}).get('application/x-www-form-urlencoded', {}).get('schema')
192+
if not spec_frm_sch:
193+
spec_frm_sch = scm.get('requestBody', {}).get('content', {}).get('multipart/form-data', {}).get('schema')
194+
if spec_frm_sch:
195+
if spec_frm_sch.get('type') != 'object':
196+
print(f"** ! form schema is not an object")
197+
for key, prop in spec_frm_sch.get('properties', {}).items():
198+
spec_params[key] = {
199+
'name': key,
200+
'in': 'form',
201+
'required': False,
202+
'schema': prop
203+
}
204+
for reqd in spec_frm_sch.get('required', []):
205+
if reqd in spec_params:
206+
spec_params[reqd]['required'] = True
207+
else:
208+
print(f"** ! param `{reqd}` marked as required but does not exist")
191209
for name in spec_params.keys():
192210
if not name in pdoc.params:
193211
print(f"** ! param `{name}` found in spec, but not in doc")
@@ -201,8 +219,9 @@ def print_cmp(name, par, spec, doc):
201219
return
202220
if spec != doc:
203221
print(f"** ! param `{name}`.`{par}`: spec `{spec}` vs doc `{doc}`")
222+
spec_sch = spec_param.get('schema', {})
204223
print_cmp(name, 'required', spec_param.get('required'), doc_param.required)
205-
print_cmp(name, 'type', spec_param.get('schema', {}).get('type'), doc_param.typ)
224+
print_cmp(name, 'type', spec_sch.get('format', spec_sch.get('type')), doc_param.typ)
206225
print_cmp(name, 'in', spec_param.get('in'), doc_param.where)
207226

208227
spec_req_sch = scm.get('requestBody', {}).get('content', {}).get('application/json', {}).get('schema')

android/.openapi-generator/FILES

+52-70
Large diffs are not rendered by default.

android/README.md

+26-35
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,6 @@ Class | Method | HTTP request | Description
206206
- [AnalyzeRecipeInstructions200ResponseParsedInstructionsInnerStepsInnerIngredientsInner](docs/AnalyzeRecipeInstructions200ResponseParsedInstructionsInnerStepsInnerIngredientsInner.md)
207207
- [AnalyzeRecipeRequest](docs/AnalyzeRecipeRequest.md)
208208
- [AutocompleteIngredientSearch200ResponseInner](docs/AutocompleteIngredientSearch200ResponseInner.md)
209-
- [AutocompleteMenuItemSearch200Response](docs/AutocompleteMenuItemSearch200Response.md)
210209
- [AutocompleteProductSearch200Response](docs/AutocompleteProductSearch200Response.md)
211210
- [AutocompleteProductSearch200ResponseResultsInner](docs/AutocompleteProductSearch200ResponseResultsInner.md)
212211
- [AutocompleteRecipeSearch200ResponseInner](docs/AutocompleteRecipeSearch200ResponseInner.md)
@@ -215,6 +214,7 @@ Class | Method | HTTP request | Description
215214
- [ClassifyGroceryProductBulk200ResponseInner](docs/ClassifyGroceryProductBulk200ResponseInner.md)
216215
- [ClassifyGroceryProductBulkRequestInner](docs/ClassifyGroceryProductBulkRequestInner.md)
217216
- [ClassifyGroceryProductRequest](docs/ClassifyGroceryProductRequest.md)
217+
- [ComparableProduct](docs/ComparableProduct.md)
218218
- [ComputeGlycemicLoad200Response](docs/ComputeGlycemicLoad200Response.md)
219219
- [ComputeGlycemicLoad200ResponseIngredientsInner](docs/ComputeGlycemicLoad200ResponseIngredientsInner.md)
220220
- [ComputeGlycemicLoadRequest](docs/ComputeGlycemicLoadRequest.md)
@@ -227,49 +227,32 @@ Class | Method | HTTP request | Description
227227
- [DetectFoodInText200ResponseAnnotationsInner](docs/DetectFoodInText200ResponseAnnotationsInner.md)
228228
- [GenerateMealPlan200Response](docs/GenerateMealPlan200Response.md)
229229
- [GenerateMealPlan200ResponseNutrients](docs/GenerateMealPlan200ResponseNutrients.md)
230-
- [GenerateShoppingList200Response](docs/GenerateShoppingList200Response.md)
231230
- [GetARandomFoodJoke200Response](docs/GetARandomFoodJoke200Response.md)
232-
- [GetAnalyzedRecipeInstructions200Response](docs/GetAnalyzedRecipeInstructions200Response.md)
233-
- [GetAnalyzedRecipeInstructions200ResponseIngredientsInner](docs/GetAnalyzedRecipeInstructions200ResponseIngredientsInner.md)
234-
- [GetAnalyzedRecipeInstructions200ResponseParsedInstructionsInner](docs/GetAnalyzedRecipeInstructions200ResponseParsedInstructionsInner.md)
235-
- [GetAnalyzedRecipeInstructions200ResponseParsedInstructionsInnerStepsInner](docs/GetAnalyzedRecipeInstructions200ResponseParsedInstructionsInnerStepsInner.md)
236-
- [GetAnalyzedRecipeInstructions200ResponseParsedInstructionsInnerStepsInnerIngredientsInner](docs/GetAnalyzedRecipeInstructions200ResponseParsedInstructionsInnerStepsInnerIngredientsInner.md)
231+
- [GetAnalyzedRecipeInstructions200ResponseInner](docs/GetAnalyzedRecipeInstructions200ResponseInner.md)
232+
- [GetAnalyzedRecipeInstructions200ResponseInnerStepsInner](docs/GetAnalyzedRecipeInstructions200ResponseInnerStepsInner.md)
233+
- [GetAnalyzedRecipeInstructions200ResponseInnerStepsInnerIngredientsInner](docs/GetAnalyzedRecipeInstructions200ResponseInnerStepsInnerIngredientsInner.md)
237234
- [GetComparableProducts200Response](docs/GetComparableProducts200Response.md)
238235
- [GetComparableProducts200ResponseComparableProducts](docs/GetComparableProducts200ResponseComparableProducts.md)
239-
- [GetComparableProducts200ResponseComparableProductsProteinInner](docs/GetComparableProducts200ResponseComparableProductsProteinInner.md)
240236
- [GetConversationSuggests200Response](docs/GetConversationSuggests200Response.md)
241237
- [GetConversationSuggests200ResponseSuggests](docs/GetConversationSuggests200ResponseSuggests.md)
242238
- [GetConversationSuggests200ResponseSuggestsInner](docs/GetConversationSuggests200ResponseSuggestsInner.md)
243239
- [GetDishPairingForWine200Response](docs/GetDishPairingForWine200Response.md)
244-
- [GetIngredientInformation200Response](docs/GetIngredientInformation200Response.md)
245-
- [GetIngredientInformation200ResponseNutrition](docs/GetIngredientInformation200ResponseNutrition.md)
246240
- [GetIngredientSubstitutes200Response](docs/GetIngredientSubstitutes200Response.md)
247241
- [GetMealPlanTemplate200Response](docs/GetMealPlanTemplate200Response.md)
248242
- [GetMealPlanTemplate200ResponseDaysInner](docs/GetMealPlanTemplate200ResponseDaysInner.md)
249243
- [GetMealPlanTemplate200ResponseDaysInnerItemsInner](docs/GetMealPlanTemplate200ResponseDaysInnerItemsInner.md)
250244
- [GetMealPlanTemplate200ResponseDaysInnerItemsInnerValue](docs/GetMealPlanTemplate200ResponseDaysInnerItemsInnerValue.md)
251245
- [GetMealPlanTemplates200Response](docs/GetMealPlanTemplates200Response.md)
246+
- [GetMealPlanTemplates200ResponseTemplatesInner](docs/GetMealPlanTemplates200ResponseTemplatesInner.md)
252247
- [GetMealPlanWeek200Response](docs/GetMealPlanWeek200Response.md)
253248
- [GetMealPlanWeek200ResponseDaysInner](docs/GetMealPlanWeek200ResponseDaysInner.md)
254249
- [GetMealPlanWeek200ResponseDaysInnerItemsInner](docs/GetMealPlanWeek200ResponseDaysInnerItemsInner.md)
255250
- [GetMealPlanWeek200ResponseDaysInnerItemsInnerValue](docs/GetMealPlanWeek200ResponseDaysInnerItemsInnerValue.md)
256251
- [GetMealPlanWeek200ResponseDaysInnerNutritionSummary](docs/GetMealPlanWeek200ResponseDaysInnerNutritionSummary.md)
257252
- [GetMealPlanWeek200ResponseDaysInnerNutritionSummaryNutrientsInner](docs/GetMealPlanWeek200ResponseDaysInnerNutritionSummaryNutrientsInner.md)
258-
- [GetMenuItemInformation200Response](docs/GetMenuItemInformation200Response.md)
259-
- [GetProductInformation200Response](docs/GetProductInformation200Response.md)
260-
- [GetProductInformation200ResponseIngredientsInner](docs/GetProductInformation200ResponseIngredientsInner.md)
261-
- [GetRandomFoodTrivia200Response](docs/GetRandomFoodTrivia200Response.md)
262253
- [GetRandomRecipes200Response](docs/GetRandomRecipes200Response.md)
263-
- [GetRandomRecipes200ResponseRecipesInner](docs/GetRandomRecipes200ResponseRecipesInner.md)
264254
- [GetRecipeEquipmentByID200Response](docs/GetRecipeEquipmentByID200Response.md)
265255
- [GetRecipeEquipmentByID200ResponseEquipmentInner](docs/GetRecipeEquipmentByID200ResponseEquipmentInner.md)
266-
- [GetRecipeInformation200Response](docs/GetRecipeInformation200Response.md)
267-
- [GetRecipeInformation200ResponseExtendedIngredientsInner](docs/GetRecipeInformation200ResponseExtendedIngredientsInner.md)
268-
- [GetRecipeInformation200ResponseExtendedIngredientsInnerMeasures](docs/GetRecipeInformation200ResponseExtendedIngredientsInnerMeasures.md)
269-
- [GetRecipeInformation200ResponseExtendedIngredientsInnerMeasuresMetric](docs/GetRecipeInformation200ResponseExtendedIngredientsInnerMeasuresMetric.md)
270-
- [GetRecipeInformation200ResponseWinePairing](docs/GetRecipeInformation200ResponseWinePairing.md)
271-
- [GetRecipeInformation200ResponseWinePairingProductMatchesInner](docs/GetRecipeInformation200ResponseWinePairingProductMatchesInner.md)
272-
- [GetRecipeInformationBulk200ResponseInner](docs/GetRecipeInformationBulk200ResponseInner.md)
273256
- [GetRecipeIngredientsByID200Response](docs/GetRecipeIngredientsByID200Response.md)
274257
- [GetRecipeIngredientsByID200ResponseIngredientsInner](docs/GetRecipeIngredientsByID200ResponseIngredientsInner.md)
275258
- [GetRecipeNutritionWidgetByID200Response](docs/GetRecipeNutritionWidgetByID200Response.md)
@@ -279,11 +262,11 @@ Class | Method | HTTP request | Description
279262
- [GetRecipePriceBreakdownByID200ResponseIngredientsInner](docs/GetRecipePriceBreakdownByID200ResponseIngredientsInner.md)
280263
- [GetRecipePriceBreakdownByID200ResponseIngredientsInnerAmount](docs/GetRecipePriceBreakdownByID200ResponseIngredientsInnerAmount.md)
281264
- [GetRecipePriceBreakdownByID200ResponseIngredientsInnerAmountMetric](docs/GetRecipePriceBreakdownByID200ResponseIngredientsInnerAmountMetric.md)
282-
- [GetRecipeTasteByID200Response](docs/GetRecipeTasteByID200Response.md)
283265
- [GetShoppingList200Response](docs/GetShoppingList200Response.md)
284266
- [GetShoppingList200ResponseAislesInner](docs/GetShoppingList200ResponseAislesInner.md)
285267
- [GetShoppingList200ResponseAislesInnerItemsInner](docs/GetShoppingList200ResponseAislesInnerItemsInner.md)
286268
- [GetShoppingList200ResponseAislesInnerItemsInnerMeasures](docs/GetShoppingList200ResponseAislesInnerItemsInnerMeasures.md)
269+
- [GetShoppingList200ResponseAislesInnerItemsInnerMeasuresOriginal](docs/GetShoppingList200ResponseAislesInnerItemsInnerMeasuresOriginal.md)
287270
- [GetSimilarRecipes200ResponseInner](docs/GetSimilarRecipes200ResponseInner.md)
288271
- [GetWineDescription200Response](docs/GetWineDescription200Response.md)
289272
- [GetWinePairing200Response](docs/GetWinePairing200Response.md)
@@ -300,33 +283,40 @@ Class | Method | HTTP request | Description
300283
- [ImageAnalysisByURL200ResponseNutritionCaloriesConfidenceRange95Percent](docs/ImageAnalysisByURL200ResponseNutritionCaloriesConfidenceRange95Percent.md)
301284
- [ImageAnalysisByURL200ResponseRecipesInner](docs/ImageAnalysisByURL200ResponseRecipesInner.md)
302285
- [ImageClassificationByURL200Response](docs/ImageClassificationByURL200Response.md)
286+
- [IngredientBasics](docs/IngredientBasics.md)
287+
- [IngredientInformation](docs/IngredientInformation.md)
288+
- [IngredientInformationEstimatedCost](docs/IngredientInformationEstimatedCost.md)
289+
- [IngredientInformationNutrition](docs/IngredientInformationNutrition.md)
290+
- [IngredientInformationNutritionPropertiesInner](docs/IngredientInformationNutritionPropertiesInner.md)
303291
- [IngredientSearch200Response](docs/IngredientSearch200Response.md)
304292
- [IngredientSearch200ResponseResultsInner](docs/IngredientSearch200ResponseResultsInner.md)
305293
- [MapIngredientsToGroceryProducts200ResponseInner](docs/MapIngredientsToGroceryProducts200ResponseInner.md)
306294
- [MapIngredientsToGroceryProducts200ResponseInnerProductsInner](docs/MapIngredientsToGroceryProducts200ResponseInnerProductsInner.md)
307295
- [MapIngredientsToGroceryProductsRequest](docs/MapIngredientsToGroceryProductsRequest.md)
308-
- [ParseIngredients200ResponseInner](docs/ParseIngredients200ResponseInner.md)
309-
- [ParseIngredients200ResponseInnerEstimatedCost](docs/ParseIngredients200ResponseInnerEstimatedCost.md)
310-
- [ParseIngredients200ResponseInnerNutrition](docs/ParseIngredients200ResponseInnerNutrition.md)
311-
- [ParseIngredients200ResponseInnerNutritionCaloricBreakdown](docs/ParseIngredients200ResponseInnerNutritionCaloricBreakdown.md)
312-
- [ParseIngredients200ResponseInnerNutritionNutrientsInner](docs/ParseIngredients200ResponseInnerNutritionNutrientsInner.md)
313-
- [ParseIngredients200ResponseInnerNutritionPropertiesInner](docs/ParseIngredients200ResponseInnerNutritionPropertiesInner.md)
314-
- [ParseIngredients200ResponseInnerNutritionWeightPerServing](docs/ParseIngredients200ResponseInnerNutritionWeightPerServing.md)
296+
- [MenuItem](docs/MenuItem.md)
297+
- [MenuItemServings](docs/MenuItemServings.md)
298+
- [ProductInformation](docs/ProductInformation.md)
299+
- [ProductInformationCredits](docs/ProductInformationCredits.md)
315300
- [QuickAnswer200Response](docs/QuickAnswer200Response.md)
301+
- [RecipeInformation](docs/RecipeInformation.md)
302+
- [RecipeInformationExtendedIngredientsInner](docs/RecipeInformationExtendedIngredientsInner.md)
303+
- [RecipeInformationExtendedIngredientsInnerMeasures](docs/RecipeInformationExtendedIngredientsInnerMeasures.md)
304+
- [RecipeInformationExtendedIngredientsInnerMeasuresMetric](docs/RecipeInformationExtendedIngredientsInnerMeasuresMetric.md)
305+
- [RecipeInformationWinePairing](docs/RecipeInformationWinePairing.md)
306+
- [RecipeInformationWinePairingProductMatchesInner](docs/RecipeInformationWinePairingProductMatchesInner.md)
316307
- [SearchAllFood200Response](docs/SearchAllFood200Response.md)
317308
- [SearchAllFood200ResponseSearchResultsInner](docs/SearchAllFood200ResponseSearchResultsInner.md)
318-
- [SearchAllFood200ResponseSearchResultsInnerResultsInner](docs/SearchAllFood200ResponseSearchResultsInnerResultsInner.md)
319309
- [SearchCustomFoods200Response](docs/SearchCustomFoods200Response.md)
320310
- [SearchCustomFoods200ResponseCustomFoodsInner](docs/SearchCustomFoods200ResponseCustomFoodsInner.md)
321311
- [SearchFoodVideos200Response](docs/SearchFoodVideos200Response.md)
322312
- [SearchFoodVideos200ResponseVideosInner](docs/SearchFoodVideos200ResponseVideosInner.md)
323313
- [SearchGroceryProducts200Response](docs/SearchGroceryProducts200Response.md)
324314
- [SearchGroceryProductsByUPC200Response](docs/SearchGroceryProductsByUPC200Response.md)
325-
- [SearchGroceryProductsByUPC200ResponseIngredientsInner](docs/SearchGroceryProductsByUPC200ResponseIngredientsInner.md)
326315
- [SearchGroceryProductsByUPC200ResponseNutrition](docs/SearchGroceryProductsByUPC200ResponseNutrition.md)
316+
- [SearchGroceryProductsByUPC200ResponseNutritionCaloricBreakdown](docs/SearchGroceryProductsByUPC200ResponseNutritionCaloricBreakdown.md)
317+
- [SearchGroceryProductsByUPC200ResponseNutritionNutrientsInner](docs/SearchGroceryProductsByUPC200ResponseNutritionNutrientsInner.md)
327318
- [SearchGroceryProductsByUPC200ResponseServings](docs/SearchGroceryProductsByUPC200ResponseServings.md)
328319
- [SearchMenuItems200Response](docs/SearchMenuItems200Response.md)
329-
- [SearchMenuItems200ResponseMenuItemsInner](docs/SearchMenuItems200ResponseMenuItemsInner.md)
330320
- [SearchRecipes200Response](docs/SearchRecipes200Response.md)
331321
- [SearchRecipes200ResponseResultsInner](docs/SearchRecipes200ResponseResultsInner.md)
332322
- [SearchRecipesByIngredients200ResponseInner](docs/SearchRecipesByIngredients200ResponseInner.md)
@@ -337,12 +327,13 @@ Class | Method | HTTP request | Description
337327
- [SearchRestaurants200ResponseRestaurantsInnerAddress](docs/SearchRestaurants200ResponseRestaurantsInnerAddress.md)
338328
- [SearchRestaurants200ResponseRestaurantsInnerLocalHours](docs/SearchRestaurants200ResponseRestaurantsInnerLocalHours.md)
339329
- [SearchRestaurants200ResponseRestaurantsInnerLocalHoursOperational](docs/SearchRestaurants200ResponseRestaurantsInnerLocalHoursOperational.md)
330+
- [SearchResult](docs/SearchResult.md)
331+
- [SearchResultDataPointsInner](docs/SearchResultDataPointsInner.md)
340332
- [SearchSiteContent200Response](docs/SearchSiteContent200Response.md)
341-
- [SearchSiteContent200ResponseArticlesInner](docs/SearchSiteContent200ResponseArticlesInner.md)
342-
- [SearchSiteContent200ResponseArticlesInnerDataPointsInner](docs/SearchSiteContent200ResponseArticlesInnerDataPointsInner.md)
343333
- [SummarizeRecipe200Response](docs/SummarizeRecipe200Response.md)
344334
- [TalkToChatbot200Response](docs/TalkToChatbot200Response.md)
345335
- [TalkToChatbot200ResponseMediaInner](docs/TalkToChatbot200ResponseMediaInner.md)
336+
- [TasteInformation](docs/TasteInformation.md)
346337

347338

348339
## Documentation for Authorization

android/docs/AnalyzeRecipeInstructions200ResponseIngredientsInner.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
Name | Type | Description | Notes
88
------------ | ------------- | ------------- | -------------
9-
**id** | [**BigDecimal**](BigDecimal.md) | |
9+
**id** | **Integer** | |
1010
**name** | **String** | |
1111

1212

android/docs/AnalyzeRecipeInstructions200ResponseParsedInstructionsInnerStepsInnerIngredientsInner.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
Name | Type | Description | Notes
88
------------ | ------------- | ------------- | -------------
9-
**id** | [**BigDecimal**](BigDecimal.md) | |
9+
**id** | **Integer** | |
1010
**name** | **String** | |
1111
**localizedName** | **String** | |
1212
**image** | **String** | |

android/docs/AutocompleteMenuItemSearch200Response.md

-13
This file was deleted.

android/docs/ComparableProduct.md

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
2+
3+
# ComparableProduct
4+
5+
## Properties
6+
7+
Name | Type | Description | Notes
8+
------------ | ------------- | ------------- | -------------
9+
**difference** | [**BigDecimal**](BigDecimal.md) | |
10+
**id** | **Integer** | |
11+
**image** | **String** | |
12+
**title** | **String** | |
13+
14+
15+
16+

android/docs/DefaultApi.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ Generate a recipe card for a recipe.
7777
//import com.spoonacular.DefaultApi;
7878

7979
DefaultApi apiInstance = new DefaultApi();
80-
BigDecimal id = 4632; // BigDecimal | The recipe id.
80+
Integer id = 4632; // Integer | The recipe id.
8181
String mask = ellipseMask; // String | The mask to put over the recipe image (\"ellipseMask\", \"diamondMask\", \"starMask\", \"heartMask\", \"potMask\", \"fishMask\").
8282
String backgroundImage = background1; // String | The background image (\"none\",\"background1\", or \"background2\").
8383
String backgroundColor = ffffff; // String | The background color for the recipe card as a hex-string.
@@ -96,7 +96,7 @@ try {
9696

9797
Name | Type | Description | Notes
9898
------------- | ------------- | ------------- | -------------
99-
**id** | **BigDecimal**| The recipe id. | [default to null]
99+
**id** | **Integer**| The recipe id. | [default to null]
100100
**mask** | **String**| The mask to put over the recipe image (\"ellipseMask\", \"diamondMask\", \"starMask\", \"heartMask\", \"potMask\", \"fishMask\"). | [optional] [default to null]
101101
**backgroundImage** | **String**| The background image (\"none\",\"background1\", or \"background2\"). | [optional] [default to null]
102102
**backgroundColor** | **String**| The background color for the recipe card as a hex-string. | [optional] [default to null]

android/docs/GenerateShoppingList200Response.md

-16
This file was deleted.

android/docs/GetAnalyzedRecipeInstructions200Response.md

-15
This file was deleted.

0 commit comments

Comments
 (0)