Skip to content
Commits on Source (2)
...@@ -6,12 +6,16 @@ from edge_cloud_management_api.managers.log_manager import logger ...@@ -6,12 +6,16 @@ from edge_cloud_management_api.managers.log_manager import logger
from edge_cloud_management_api.services.edge_cloud_services import PiEdgeAPIClientFactory from edge_cloud_management_api.services.edge_cloud_services import PiEdgeAPIClientFactory
from edge_cloud_management_api.services.storage_service import insert_zones from edge_cloud_management_api.services.storage_service import insert_zones
try:
pi_edge_factory = PiEdgeAPIClientFactory() pi_edge_factory = PiEdgeAPIClientFactory()
api_client = pi_edge_factory.create_pi_edge_api_client() api_client = pi_edge_factory.create_pi_edge_api_client()
zones = api_client.edge_cloud_zones() zones = api_client.edge_cloud_zones()
for zone in zones: for zone in zones:
zone['_id'] = zone.get('edgeCloudZoneId') zone['_id'] = zone.get('edgeCloudZoneId')
insert_zones(zones) insert_zones(zones)
except Exception as e:
logger.error(e.args)
class EdgeCloudZone(BaseModel): class EdgeCloudZone(BaseModel):
edgeCloudZoneId: str = Field(..., description="Unique identifier of the Edge Cloud Zone") edgeCloudZoneId: str = Field(..., description="Unique identifier of the Edge Cloud Zone")
...@@ -47,8 +51,6 @@ def get_local_zones() -> list[dict]: ...@@ -47,8 +51,6 @@ def get_local_zones() -> list[dict]:
if isinstance(result, dict) and "error" in result: if isinstance(result, dict) and "error" in result:
logger.error(f"SRM error: {result['error']}") logger.error(f"SRM error: {result['error']}")
return [] return []
return result return result
except Exception as e: except Exception as e:
......
...@@ -17,28 +17,28 @@ def create_federation(): ...@@ -17,28 +17,28 @@ def create_federation():
body = request.get_json() body = request.get_json()
token = __get_token() token = __get_token()
response = federation_client.post_partner(body, token) response, code = federation_client.post_partner(body, token)
return jsonify(response) return response, code
def get_federation(federationContextId): def get_federation(federationContextId):
"""GET /{federationContextId}/partner - Get federation info.""" """GET /{federationContextId}/partner - Get federation info."""
token = __get_token() token = __get_token()
result = federation_client.get_partner(federationContextId, token) response, code = federation_client.get_partner(federationContextId, token)
return jsonify(result) return response, code
def delete_federation(federationContextId): def delete_federation(federationContextId):
"""DELETE /{federationContextId}/partner - Delete federation.""" """DELETE /{federationContextId}/partner - Delete federation."""
token = __get_token() token = __get_token()
result = federation_client.delete_partner(federationContextId, token) response, code = federation_client.delete_partner(federationContextId, token)
return jsonify(result) return response, code
def get_federation_context_ids(): def get_federation_context_ids():
"""GET /fed-context-id - Fetch federationContextId(s).""" """GET /fed-context-id - Fetch federationContextId(s)."""
token = __get_token() token = __get_token()
response = federation_client.get_federation_context_ids(token) response, code = federation_client.get_federation_context_ids(token)
return jsonify(response) return response, code
def onboard_application_to_partner(federationContextId): def onboard_application_to_partner(federationContextId):
...@@ -64,6 +64,23 @@ def delete_onboarded_app(federationContextId, appId): ...@@ -64,6 +64,23 @@ def delete_onboarded_app(federationContextId, appId):
result = federation_client.delete_onboarded_app(federationContextId, appId, token) result = federation_client.delete_onboarded_app(federationContextId, appId, token)
return jsonify(result) return jsonify(result)
'''---AVAILABILITY ZONE INFO SYNCHRONIZATION---'''
def request_zone_synch(federationContextId):
token = __get_token()
body = request.get_json()
response = federation_client.request_zone_sync(federation_context_id=federationContextId, body=body, token=token)
return jsonify(response)
def get_zone_resource_info(federationContextId, zoneId):
token = __get_token()
response = federation_client.get_zone_resource_info(federation_context_id=federationContextId, zone_id=zoneId, token=token)
return jsonify(response)
def remove_zone_sync(federationContextId, zoneId):
token = __get_token()
response = federation_client.remove_zone_sync(federation_context_id=federationContextId, zone_id=zoneId, token=token)
return jsonify(response)
def __get_token(): def __get_token():
bearer = connexion.request.headers['Authorization'] bearer = connexion.request.headers['Authorization']
......
...@@ -18,83 +18,86 @@ class FederationManagerClient: ...@@ -18,83 +18,86 @@ class FederationManagerClient:
headers['Accept'] = 'application/json' headers['Accept'] = 'application/json'
return headers return headers
'''---FEDERATION ESTABLISHMENT---'''
def post_partner(self, data: dict, token: str): def post_partner(self, data: dict, token: str):
url = f"{self.base_url}/partner" url = f"{self.base_url}/partner"
try: try:
response = requests.post(url, json=data, headers=self._get_headers(token), timeout=10) response = requests.post(url, json=data, headers=self._get_headers(token), timeout=10)
response.raise_for_status() response.raise_for_status()
return response.json() return response.json(), 200
except Timeout: except Timeout:
logger.error("POST /partner timed out") logger.error("POST /partner timed out")
return {"error": "Request timed out"}, 408 return {"error": "Request timed out"}, 408
except ConnectionError: except ConnectionError:
logger.error("POST /partner connection error") logger.error("POST /partner connection error")
return {"error": "Connection error"} return {"error": "Connection error"}, 504
except requests.exceptions.HTTPError as http_err: except requests.exceptions.HTTPError as http_err:
logger.error(f"POST /partner HTTP error: {http_err}") logger.error(f"POST /partner HTTP error: {http_err}")
return {"error": str(http_err), "status_code": response.status_code} return {'Error': http_err.response.json().get('detail')}, response.status_code
except Exception as e: except Exception as e:
logger.error(f"POST /partner unexpected error: {e}") logger.error(f"POST /partner unexpected error: {e}")
return {"error": str(e)} return {"error": str(e)}, 500
def get_partner(self, federation_context_id: str, token: str): def get_partner(self, federation_context_id: str, token: str):
url = f"{self.base_url}/{federation_context_id}/partner" url = f"{self.base_url}/{federation_context_id}/partner"
try: try:
response = requests.get(url, headers=self._get_headers(token), timeout=10) response = requests.get(url, headers=self._get_headers(token), timeout=10)
response.raise_for_status() response.raise_for_status()
return response.json() return response.json(), 200
except Timeout: except Timeout:
logger.error("GET /{id}/partner timed out") logger.error("GET /{id}/partner timed out")
return {"error": "Request timed out"} return {"error": "Request timed out"}, 408
except ConnectionError: except ConnectionError:
logger.error("GET /{id}/partner connection error") logger.error("GET /{id}/partner connection error")
return {"error": "Connection error"} return {"error": "Connection error"}, 504
except requests.exceptions.HTTPError as http_err: except requests.exceptions.HTTPError as http_err:
logger.error(f"GET /{id}/partner HTTP error: {http_err}") logger.error(f"GET /{id}/partner HTTP error: {http_err}")
return {"error": str(http_err), "status_code": response.status_code} return {'Error': http_err.response.json().get('detail')}, response.status_code
except Exception as e: except Exception as e:
logger.error(f"GET /{id}/partner unexpected error: {e}") logger.error(f"GET /{id}/partner unexpected error: {e}")
return {"error": str(e)} return {"error": str(e)}, 500
def delete_partner(self, federation_context_id: str, token: str): def delete_partner(self, federation_context_id: str, token: str):
url = f"{self.base_url}/{federation_context_id}/partner" url = f"{self.base_url}/{federation_context_id}/partner"
try: try:
response = requests.delete(url, headers=self._get_headers(token), timeout=10) response = requests.delete(url, headers=self._get_headers(token), timeout=10)
if response.content: if response.content:
return response.json() return response.json(), 200
return {"status": response.status_code} return {"status": response.status_code}
except Timeout: except Timeout:
logger.error("DELETE /{id}/partner timed out") logger.error("DELETE /{id}/partner timed out")
return {"error": "Request timed out"} return {"error": "Request timed out"}, 408
except ConnectionError: except ConnectionError:
logger.error("DELETE /{id}/partner connection error") logger.error("DELETE /{id}/partner connection error")
return {"error": "Connection error"} return {"error": "Connection error"}, 504
except requests.exceptions.HTTPError as http_err: except requests.exceptions.HTTPError as http_err:
logger.error(f"DELETE /{id}/partner HTTP error: {http_err}") logger.error(f"DELETE /{id}/partner HTTP error: {http_err}")
return {"error": str(http_err), "status_code": response.status_code} return {'Error': http_err.response.json().get('detail')}, response.status_code
except Exception as e: except Exception as e:
logger.error(f"DELETE /{id}/partner unexpected error: {e}") logger.error(f"DELETE /{id}/partner unexpected error: {e}")
return {"error": str(e)} return {"error": str(e)}, 500
def get_federation_context_ids(self, token: str): def get_federation_context_ids(self, token: str):
url = f"{self.base_url}/fed-context-id" url = f"{self.base_url}/fed-context-id"
try: try:
response = requests.get(url, headers=self._get_headers(token), timeout=10) response = requests.get(url, headers=self._get_headers(token), timeout=10)
response.raise_for_status() response.raise_for_status()
return response.json() return response.json(), 200
except Timeout: except Timeout:
logger.error("GET /fed-context-id timed out") logger.error("GET /fed-context-id timed out")
return {"error": "Request timed out"} return {"error": "Request timed out"}, 408
except ConnectionError: except ConnectionError:
logger.error("GET /fed-context-id connection error") logger.error("GET /fed-context-id connection error")
return {"error": "Connection error"} return {"error": "Connection error"}, 504
except requests.exceptions.HTTPError as http_err: except requests.exceptions.HTTPError as http_err:
logger.error(f"GET /fed-context-id HTTP error: {http_err}") logger.error(f"GET /fed-context-id HTTP error: {http_err}")
if response.status_code==404: return {'Error': http_err.response.json().get('detail')}, response.status_code
return {'erorr': http_err}, 404
except Exception as e: except Exception as e:
logger.error(f"GET /fed-context-id unexpected error: {e}") logger.error(f"GET /fed-context-id unexpected error: {e}")
return {"error": str(e)} return {"error": str(e)}, 500
'''---PARTNER APP ONBOARDING---'''
def onboard_application(self, federation_context_id: str, body: dict, token: str): def onboard_application(self, federation_context_id: str, body: dict, token: str):
url = f"{self.base_url}/{federation_context_id}/application/onboarding" url = f"{self.base_url}/{federation_context_id}/application/onboarding"
...@@ -138,12 +141,12 @@ class FederationManagerClient: ...@@ -138,12 +141,12 @@ class FederationManagerClient:
def delete_onboarded_app(self, federation_context_id: str, app_id: str, token: str): def delete_onboarded_app(self, federation_context_id: str, app_id: str, token: str):
url = f"{self.base_url}/{federation_context_id}/application/onboarding/app/{app_id}" url = f"{self.base_url}/{federation_context_id}/application/onboarding/app/{app_id}"
try: try:
response = requests.delete(url, headers=self._get_headers(), timeout=10) response = requests.delete(url, headers=self._get_headers(token), timeout=10)
response.raise_for_status() response.raise_for_status()
return {"message": "Deleted successfully", "status_code": response.status_code} return {"message": "Deleted successfully", "status_code": response.status_code}
except Timeout: except Timeout:
logger.error("DELETE onboarding app timed out") logger.error("DELETE onboarding app timed out")
return {"error": "Request timed out", "status_code": 504} return {"error": "Request timed out", "status_code": 408}
except ConnectionError: except ConnectionError:
logger.error("DELETE onboarding app connection error") logger.error("DELETE onboarding app connection error")
return {"error": "Connection error", "status_code": 503} return {"error": "Connection error", "status_code": 503}
...@@ -154,6 +157,67 @@ class FederationManagerClient: ...@@ -154,6 +157,67 @@ class FederationManagerClient:
logger.error(f"DELETE onboarding app unexpected error: {e}") logger.error(f"DELETE onboarding app unexpected error: {e}")
return {"error": str(e), "status_code": 500} return {"error": str(e), "status_code": 500}
'''---PARTNER APP DEPLOYMENT---'''
'''---AVAILABILITY ZONE INFO SYNCHRONIZATION---'''
def request_zone_sync(self, federation_context_id: str, body: dict, token: str):
url = f"{self.base_url}/{federation_context_id}/zones"
try:
response = requests.post(url, headers=self._get_headers(token), json=body, timeout=10)
return response.json()
except Timeout:
logger.error("Zone synchronization timed out")
return {"error": "Request timed out", "status_code": 408}
except ConnectionError:
logger.error("Zone synchronization connection error")
return {"error": "Connection error", "status_code": 503}
except requests.exceptions.HTTPError as http_err:
logger.error(f"Zone synchronization HTTP error: {http_err}")
return {"error": str(http_err), "status_code": response.status_code}
except Exception as e:
logger.error(f"Zone synchronization unexpected error: {e}")
return {"error": str(e), "status_code": 500}
def get_zone_resource_info(self, federation_context_id: str, zone_id: str, token: str):
url = f"{self.base_url}/{federation_context_id}/zones/{zone_id}"
try:
response = requests.get(url, headers=self._get_headers(token), timeout=10)
return response.json()
except Timeout:
logger.error("Zone resource info timed out")
return {"error": "Request timed out", "status_code": 408}
except ConnectionError:
logger.error("Zone resource info connection error")
return {"error": "Connection error", "status_code": 503}
except requests.exceptions.HTTPError as http_err:
logger.error(f"Zone resource info HTTP error: {http_err}")
return {"error": str(http_err), "status_code": response.status_code}
except Exception as e:
logger.error(f"Zone resource info unexpected error: {e}")
return {"error": str(e), "status_code": 500}
def remove_zone_sync(self, federation_context_id: str, zone_id: str, token: str):
url = f"{self.base_url}/{federation_context_id}/zones/{zone_id}"
try:
response = requests.delete(url, headers=self._get_headers(token), timeout=10)
return response.json()
except Timeout:
logger.error("Remove Zone sync timed out")
return {"error": "Request timed out", "status_code": 408}
except ConnectionError:
logger.error("Remove Zone sync connection error")
return {"error": "Connection error", "status_code": 503}
except requests.exceptions.HTTPError as http_err:
logger.error(f"Remove Zone sync HTTP error: {http_err}")
return {"error": str(http_err), "status_code": response.status_code}
except Exception as e:
logger.error(f"Remove Zone sync unexpected error: {e}")
return {"error": str(e), "status_code": 500}
class FederationManagerClientFactory: class FederationManagerClientFactory:
......
...@@ -854,189 +854,189 @@ paths: ...@@ -854,189 +854,189 @@ paths:
application/json: application/json:
schema: schema:
$ref: '#/components/schemas/FederationResponseData' $ref: '#/components/schemas/FederationResponseData'
"400": # "400":
description: Bad request # description: Bad request
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"404": # "404":
description: Unauthorized # description: Unauthorized
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"408": # "408":
description: Timeout # description: Timeout
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"409": # "409":
description: Conflict # description: Conflict
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"500": # "500":
description: Internal Server Error # description: Internal Server Error
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
callbacks: # callbacks:
onPartnerStatusEvent: # onPartnerStatusEvent:
'{$request.body#/partnerStatusLink }': # '{$request.body#/partnerStatusLink }':
post: # post:
requestBody: # requestBody:
description: | # description: |
OP uses this callback api to notify partner OP about change in federation status, federation metadata or offered zone details. Allowed combinations of objectType and operationType are # OP uses this callback api to notify partner OP about change in federation status, federation metadata or offered zone details. Allowed combinations of objectType and operationType are
- FEDERATION - STATUS: Status specified by parameter 'federationStatus'. # - FEDERATION - STATUS: Status specified by parameter 'federationStatus'.
- ZONES - STATUS: Status specified by parameter 'zoneStatus'. # - ZONES - STATUS: Status specified by parameter 'zoneStatus'.
- ZONES - ADD: Use parameter 'addZones' to define add new zones # - ZONES - ADD: Use parameter 'addZones' to define add new zones
- ZONES - REMOVE: Use parameter 'removeZones' to define remove zones. # - ZONES - REMOVE: Use parameter 'removeZones' to define remove zones.
- EDGE_DISCOVERY_SERVICE - UPDATE: Use parameter 'edgeDiscoverySvcEndPoint' to specify new endpoints # - EDGE_DISCOVERY_SERVICE - UPDATE: Use parameter 'edgeDiscoverySvcEndPoint' to specify new endpoints
- LCM_SERVICE - UPDATE: Use parameter 'lcmSvcEndPoint' to specify new endpoints # - LCM_SERVICE - UPDATE: Use parameter 'lcmSvcEndPoint' to specify new endpoints
- MOBILE_NETWORK_CODES - ADD: Use parameter 'addMobileNetworkIds' to define new mobile network codes. # - MOBILE_NETWORK_CODES - ADD: Use parameter 'addMobileNetworkIds' to define new mobile network codes.
- MOBILE_NETWORK_CODES - REMOVE: Use parameter 'removeMobileNetworkIds' to remove mobile network codes. # - MOBILE_NETWORK_CODES - REMOVE: Use parameter 'removeMobileNetworkIds' to remove mobile network codes.
- FIXED_NETWORK_CODES - ADD: Use parameter 'addFixedNetworkIds' to define new fixed network codes. # - FIXED_NETWORK_CODES - ADD: Use parameter 'addFixedNetworkIds' to define new fixed network codes.
- FIXED_NETWORK_CODES - REMOVE: Use parameter 'removeFixedNetworkIds' to remove fixed network codes. # - FIXED_NETWORK_CODES - REMOVE: Use parameter 'removeFixedNetworkIds' to remove fixed network codes.
- SERVICE_APIS - ADD/REMOVE: Parameter Usage 'addServiceAPIs / removeServiceAPIs' to add or remove Service APIs support. # - SERVICE_APIS - ADD/REMOVE: Parameter Usage 'addServiceAPIs / removeServiceAPIs' to add or remove Service APIs support.
content: # content:
application/json: # application/json:
schema: # schema:
required: # required:
- federationContextId # - federationContextId
- modificationDate # - modificationDate
- objectType # - objectType
- operationType # - operationType
type: object # type: object
properties: # properties:
federationContextId: # federationContextId:
$ref: '#/components/schemas/FederationIdentifier' # $ref: '#/components/schemas/FederationIdentifier'
objectType: # objectType:
type: string # type: string
enum: # enum:
- FEDERATION # - FEDERATION
- ZONES # - ZONES
- EDGE_DISCOVERY_SERVICE # - EDGE_DISCOVERY_SERVICE
- LCM_SERVICE # - LCM_SERVICE
- MOBILE_NETWORK_CODES # - MOBILE_NETWORK_CODES
- FIXED_NETWORK_CODES # - FIXED_NETWORK_CODES
- SERVICE_APIS # - SERVICE_APIS
operationType: # operationType:
type: string # type: string
enum: # enum:
- STATUS # - STATUS
- UPDATE # - UPDATE
- ADD # - ADD
- REMOVE # - REMOVE
edgeDiscoverySvcEndPoint: # edgeDiscoverySvcEndPoint:
$ref: '#/components/schemas/ServiceEndpoint' # $ref: '#/components/schemas/ServiceEndpoint'
lcmSvcEndPoint: # lcmSvcEndPoint:
$ref: '#/components/schemas/ServiceEndpoint' # $ref: '#/components/schemas/ServiceEndpoint'
addMobileNetworkIds: # addMobileNetworkIds:
$ref: '#/components/schemas/MobileNetworkIds' # $ref: '#/components/schemas/MobileNetworkIds'
removeMobileNetworkIds: # removeMobileNetworkIds:
$ref: '#/components/schemas/MobileNetworkIds' # $ref: '#/components/schemas/MobileNetworkIds'
addFixedNetworkIds: # addFixedNetworkIds:
$ref: '#/components/schemas/FixedNetworkIds' # $ref: '#/components/schemas/FixedNetworkIds'
removeFixedNetworkIds: # removeFixedNetworkIds:
$ref: '#/components/schemas/FixedNetworkIds' # $ref: '#/components/schemas/FixedNetworkIds'
addZones: # addZones:
minItems: 1 # minItems: 1
type: array # type: array
description: "List of zones, which the operator platform\ # description: "List of zones, which the operator platform\
\ wishes to make available to developers/ISVs of requesting\ # \ wishes to make available to developers/ISVs of requesting\
\ operator platform." # \ operator platform."
items: # items:
$ref: '#/components/schemas/ZoneDetails' # $ref: '#/components/schemas/ZoneDetails'
removeZones: # removeZones:
minItems: 1 # minItems: 1
type: array # type: array
description: "List of zones, which the operator platform\ # description: "List of zones, which the operator platform\
\ no longer wishes to share." # \ no longer wishes to share."
items: # items:
$ref: '#/components/schemas/ZoneIdentifier' # $ref: '#/components/schemas/ZoneIdentifier'
addServiceAPIs: # addServiceAPIs:
$ref: '#/components/schemas/serviceAPINames' # $ref: '#/components/schemas/serviceAPINames'
removeServiceAPIs: # removeServiceAPIs:
$ref: '#/components/schemas/serviceAPINames' # $ref: '#/components/schemas/serviceAPINames'
zoneStatus: # zoneStatus:
minItems: 1 # minItems: 1
type: array # type: array
items: # items:
required: # required:
- status # - status
- zoneId # - zoneId
type: object # type: object
properties: # properties:
zoneId: # zoneId:
$ref: '#/components/schemas/ZoneIdentifier' # $ref: '#/components/schemas/ZoneIdentifier'
status: # status:
$ref: '#/components/schemas/Status' # $ref: '#/components/schemas/Status'
federationStatus: # federationStatus:
$ref: '#/components/schemas/Status' # $ref: '#/components/schemas/Status'
modificationDate: # modificationDate:
type: string # type: string
description: Date and time of the federation modification # description: Date and time of the federation modification
by the originating partner OP # by the originating partner OP
format: date-time # format: date-time
responses: # responses:
"204": # "204":
description: Expected response to a successful call back processing # description: Expected response to a successful call back processing
"400": # "400":
description: Bad request # description: Bad request
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"401": # "401":
description: Unauthorized # description: Unauthorized
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"404": # "404":
description: Not Found # description: Not Found
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"409": # "409":
description: Conflict # description: Conflict
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"422": # "422":
description: Unprocessable Entity # description: Unprocessable Entity
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"500": # "500":
description: Internal Server Error # description: Internal Server Error
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"503": # "503":
description: Service Unavailable # description: Service Unavailable
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"520": # "520":
description: Web Server Returned an Unknown Error # description: Web Server Returned an Unknown Error
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
default: # default:
description: Generic Error # description: Generic Error
/{federationContextId}/partner: /{federationContextId}/partner:
get: get:
...@@ -1065,24 +1065,24 @@ paths: ...@@ -1065,24 +1065,24 @@ paths:
application/json: application/json:
schema: schema:
$ref: '#/components/schemas/inline_response_200_1' $ref: '#/components/schemas/inline_response_200_1'
"401": # "401":
description: Unauthorized # description: Unauthorized
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"404": # "404":
description: Not Found # description: Not Found
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"500": # "500":
description: Internal Server Error # description: Internal Server Error
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
delete: delete:
tags: tags:
- FederationManagement - FederationManagement
...@@ -1102,24 +1102,24 @@ paths: ...@@ -1102,24 +1102,24 @@ paths:
responses: responses:
"200": "200":
description: Federation removed successfully description: Federation removed successfully
"401": # "401":
description: Unauthorized # description: Unauthorized
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"404": # "404":
description: Not Found # description: Not Found
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"500": # "500":
description: Internal Server Error # description: Internal Server Error
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
/fed-context-id: /fed-context-id:
get: get:
tags: tags:
...@@ -1132,43 +1132,41 @@ paths: ...@@ -1132,43 +1132,41 @@ paths:
responses: responses:
"200": "200":
description: Federation context identifier retrieval request accepted description: Federation context identifier retrieval request accepted
headers:
Location:
description: "Contains the URI of the existing resource, according to\
\ the structure: {apiRoot}/operatorplatform/federation/v1/partner/{federationContextId}"
required: true
style: simple
explode: false
schema:
type: string
Accept-Encoding:
description: "Accept-Encoding, described in IETF RFC 7694"
style: simple
explode: false
schema:
type: string
Content-Encoding:
description: "Content-Encoding, described in IETF RFC 7231"
style: simple
explode: false
schema:
type: string
content: content:
application/json: application/json:
schema: schema:
$ref: '#/components/schemas/inline_response_200_2' $ref: '#/components/schemas/inline_response_200_2'
"401": # "401":
description: Unauthorized # description: Unauthorized
content: # content:
application:/problem+json: # application:/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
"404": # "404":
description: Not Found # description: Not Found
content: # content:
application/problem+json: # application/problem+json:
schema: # schema:
$ref: '#/components/schemas/ProblemDetails' # $ref: '#/components/schemas/ProblemDetails'
# "408":
# description: Request timed out
# content:
# application/problem+json:
# schema:
# $ref: '#/components/schemas/ProblemDetails'
# "504":
# description: Connection Error
# content:
# application/problem+json:
# schema:
# $ref: '#/components/schemas/ProblemDetails'
# "500":
# description: Interal Server Error
# content:
# application/problem+json:
# schema:
# $ref: '#/components/schemas/ProblemDetails'
components: components:
# securitySchemes: # securitySchemes:
......