$tags =
[$this->
convertToHumanReadable($definition->
getEntityName())];
if ($experimental =
$this->
isExperimental($definition)) { $tags[] = 'Experimental';
} return new Get([ 'summary' => 'Detailed information about a ' .
$this->
convertToHumanReadable($definition->
getEntityName()) . ' resource.' .
($experimental ? ' Experimental API, not part of our backwards compatibility promise, thus this API can introduce breaking changes at any time.' : ''
),
'description' =>
$definition->
since() ? 'Available since: ' .
$definition->
since() : '',
'operationId' => 'get' .
$this->
convertToOperationId($definition->
getEntityName()),
'tags' =>
$tags,
'parameters' =>
[$this->
getIdParameter($definition)],
'responses' =>
[ Response::HTTP_OK =>
$this->
getDetailResponse($schemaName),
Response::HTTP_NOT_FOUND =>
$this->
getResponseRef((string) Response::HTTP_NOT_FOUND
),
Response::HTTP_UNAUTHORIZED =>
$this->
getResponseRef((string) Response::HTTP_UNAUTHORIZED
),
],
]);
} private function getCreatePath(EntityDefinition
$definition): Post
{ $schemaName =
$this->
snakeCaseToCamelCase($definition->
getEntityName());