Interface APIManagerInterface

  • All Known Implementing Classes:
    APIManagerClient

    public interface APIManagerInterface
    APIManagerInterface defines the client side interface for the Data Manager OMAS that is relevant for API assets that provide call-based services. It provides the ability to define and maintain the metadata about an API and the APIOperations that define the operations and parameters of the API.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.String createAPI​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, boolean apiManagerIsHome, java.lang.String endpointGUID, APIProperties apiProperties)
      Create a new metadata element to represent an API.
      java.lang.String createAPIFromTemplate​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, boolean apiManagerIsHome, java.lang.String endpointGUID, java.lang.String templateGUID, TemplateProperties templateProperties)
      Create a new metadata element to represent an API using an existing metadata element as a template.
      java.lang.String createAPIOperation​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiGUID, APIOperationProperties properties)
      Create a new metadata element to represent an API Operation.
      java.lang.String createAPIOperationFromTemplate​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String templateGUID, java.lang.String apiGUID, TemplateProperties templateProperties)
      Create a new metadata element to represent a an API Operation using an existing API Operation as a template.
      java.lang.String createAPIParameterList​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiOperationGUID, APIParameterListType parameterListType, APIParameterListProperties properties)
      Create a new metadata element to represent an API Operation's Parameter list.
      java.lang.String createAPIParameterListFromTemplate​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String templateGUID, java.lang.String apiOperationGUID, APIParameterListType parameterListType, TemplateProperties templateProperties)
      Create a new metadata element to represent a an API Parameter List using an existing API Parameter List as a template.
      java.util.List<APIOperationElement> findAPIOperations​(java.lang.String userId, java.lang.String searchString, int startFrom, int pageSize)
      Retrieve the list of API Operations metadata elements that contain the search string.
      java.util.List<APIParameterListElement> findAPIParameterLists​(java.lang.String userId, java.lang.String searchString, int startFrom, int pageSize)
      Retrieve the list of API Parameter List metadata elements that contain the search string.
      java.util.List<APIElement> findAPIs​(java.lang.String userId, java.lang.String searchString, int startFrom, int pageSize)
      Retrieve the list of API metadata elements that contain the search string.
      APIElement getAPIByGUID​(java.lang.String userId, java.lang.String guid)
      Retrieve the API metadata element with the supplied unique identifier.
      APIOperationElement getAPIOperationByGUID​(java.lang.String userId, java.lang.String guid)
      Retrieve the API Operation metadata element with the supplied unique identifier.
      java.util.List<APIOperationElement> getAPIOperationsByName​(java.lang.String userId, java.lang.String name, int startFrom, int pageSize)
      Retrieve the list of API Operations metadata elements with a matching qualified or display name.
      APIParameterListElement getAPIParameterListByGUID​(java.lang.String userId, java.lang.String guid)
      Retrieve the API Parameter List metadata element with the supplied unique identifier.
      java.util.List<APIParameterListElement> getAPIParameterListsByName​(java.lang.String userId, java.lang.String name, int startFrom, int pageSize)
      Retrieve the list of API Parameter List metadata elements with a matching qualified or display name.
      java.util.List<APIElement> getAPIsByName​(java.lang.String userId, java.lang.String name, int startFrom, int pageSize)
      Retrieve the list of API metadata elements with a matching qualified or display name.
      java.util.List<APIElement> getAPIsForAPIManager​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, int startFrom, int pageSize)
      Retrieve the list of APIs created by this caller.
      java.util.List<APIElement> getAPIsForEndpoint​(java.lang.String userId, java.lang.String endpointGUID, int startFrom, int pageSize)
      Retrieve the list of APIs connected to the requested endpoint.
      java.util.List<APIOperationElement> getOperationsForAPI​(java.lang.String userId, java.lang.String apiGUID, int startFrom, int pageSize)
      Return the list of API Parameter Lists associated with an API Operation.
      java.util.List<APIParameterListElement> getParameterListsForAPIOperation​(java.lang.String userId, java.lang.String apiOperationGUID, int startFrom, int pageSize)
      Return the list of API Parameter Lists associated with an API Operation.
      void publishAPI​(java.lang.String userId, java.lang.String apiGUID)
      Update the zones for the API asset so that it becomes visible to consumers.
      void removeAPI​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiGUID, java.lang.String qualifiedName)
      Remove the metadata element representing an API.
      void removeAPIOperation​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiOperationGUID, java.lang.String qualifiedName)
      Remove an API Operation.
      void removeAPIParameterList​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiParameterListGUID, java.lang.String qualifiedName)
      Remove an API Parameter List and all of its parameters.
      void updateAPI​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiGUID, boolean isMergeUpdate, APIProperties apiProperties)
      Update the metadata element representing an API.
      void updateAPIOperation​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiOperationGUID, boolean isMergeUpdate, APIOperationProperties properties)
      Update the metadata element representing an API Operation.
      void updateAPIParameterList​(java.lang.String userId, java.lang.String apiManagerGUID, java.lang.String apiManagerName, java.lang.String apiParameterListGUID, boolean isMergeUpdate, APIParameterListProperties properties)
      Update the metadata element representing an API ParameterList.
      void withdrawAPI​(java.lang.String userId, java.lang.String apiGUID)
      Update the zones for the API asset so that it is no longer visible to consumers.
    • Method Detail

      • createAPI

        java.lang.String createAPI​(java.lang.String userId,
                                   java.lang.String apiManagerGUID,
                                   java.lang.String apiManagerName,
                                   boolean apiManagerIsHome,
                                   java.lang.String endpointGUID,
                                   APIProperties apiProperties)
                            throws InvalidParameterException,
                                   UserNotAuthorizedException,
                                   PropertyServerException
        Create a new metadata element to represent an API.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiManagerIsHome - should the API be marked as owned by the API manager so others can not update?
        endpointGUID - unique identifier of the endpoint where this API is located
        apiProperties - properties to store
        Returns:
        unique identifier of the new metadata element
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • createAPIFromTemplate

        java.lang.String createAPIFromTemplate​(java.lang.String userId,
                                               java.lang.String apiManagerGUID,
                                               java.lang.String apiManagerName,
                                               boolean apiManagerIsHome,
                                               java.lang.String endpointGUID,
                                               java.lang.String templateGUID,
                                               TemplateProperties templateProperties)
                                        throws InvalidParameterException,
                                               UserNotAuthorizedException,
                                               PropertyServerException
        Create a new metadata element to represent an API using an existing metadata element as a template.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiManagerIsHome - should the API be marked as owned by the API manager so others can not update?
        endpointGUID - unique identifier of the endpoint where this API is located
        templateGUID - unique identifier of the metadata element to copy
        templateProperties - properties that override the template
        Returns:
        unique identifier of the new metadata element
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • updateAPI

        void updateAPI​(java.lang.String userId,
                       java.lang.String apiManagerGUID,
                       java.lang.String apiManagerName,
                       java.lang.String apiGUID,
                       boolean isMergeUpdate,
                       APIProperties apiProperties)
                throws InvalidParameterException,
                       UserNotAuthorizedException,
                       PropertyServerException
        Update the metadata element representing an API.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiGUID - unique identifier of the metadata element to update
        isMergeUpdate - are unspecified properties unchanged (true) or removed?
        apiProperties - new properties for this element
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • withdrawAPI

        void withdrawAPI​(java.lang.String userId,
                         java.lang.String apiGUID)
                  throws InvalidParameterException,
                         UserNotAuthorizedException,
                         PropertyServerException
        Update the zones for the API asset so that it is no longer visible to consumers. (The zones are set to the list of zones in the defaultZones option configured for each instance of the Data Manager OMAS. This is the setting when the API is first created).
        Parameters:
        userId - calling user
        apiGUID - unique identifier of the metadata element to withdraw
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • removeAPI

        void removeAPI​(java.lang.String userId,
                       java.lang.String apiManagerGUID,
                       java.lang.String apiManagerName,
                       java.lang.String apiGUID,
                       java.lang.String qualifiedName)
                throws InvalidParameterException,
                       UserNotAuthorizedException,
                       PropertyServerException
        Remove the metadata element representing an API.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiGUID - unique identifier of the metadata element to remove
        qualifiedName - unique name of the metadata element to remove
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • findAPIs

        java.util.List<APIElement> findAPIs​(java.lang.String userId,
                                            java.lang.String searchString,
                                            int startFrom,
                                            int pageSize)
                                     throws InvalidParameterException,
                                            UserNotAuthorizedException,
                                            PropertyServerException
        Retrieve the list of API metadata elements that contain the search string. The search string is treated as a regular expression.
        Parameters:
        userId - calling user
        searchString - string to find in the properties
        startFrom - paging start point
        pageSize - maximum results that can be returned
        Returns:
        list of matching metadata elements
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • getAPIsForAPIManager

        java.util.List<APIElement> getAPIsForAPIManager​(java.lang.String userId,
                                                        java.lang.String apiManagerGUID,
                                                        java.lang.String apiManagerName,
                                                        int startFrom,
                                                        int pageSize)
                                                 throws InvalidParameterException,
                                                        UserNotAuthorizedException,
                                                        PropertyServerException
        Retrieve the list of APIs created by this caller.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the API manager (API manager)
        apiManagerName - unique name of software server capability representing the API manager (API manager)
        startFrom - paging start point
        pageSize - maximum results that can be returned
        Returns:
        list of matching metadata elements
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • createAPIOperation

        java.lang.String createAPIOperation​(java.lang.String userId,
                                            java.lang.String apiManagerGUID,
                                            java.lang.String apiManagerName,
                                            java.lang.String apiGUID,
                                            APIOperationProperties properties)
                                     throws InvalidParameterException,
                                            UserNotAuthorizedException,
                                            PropertyServerException
        Create a new metadata element to represent an API Operation. This describes the structure of an operation supported by the API. The structure of this API Operation is added using API Parameter Lists. These parameter lists can have a simple type or a nested structure.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiGUID - unique identifier of an API
        properties - properties about the API Operation
        Returns:
        unique identifier of the new API Operation
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • createAPIOperationFromTemplate

        java.lang.String createAPIOperationFromTemplate​(java.lang.String userId,
                                                        java.lang.String apiManagerGUID,
                                                        java.lang.String apiManagerName,
                                                        java.lang.String templateGUID,
                                                        java.lang.String apiGUID,
                                                        TemplateProperties templateProperties)
                                                 throws InvalidParameterException,
                                                        UserNotAuthorizedException,
                                                        PropertyServerException
        Create a new metadata element to represent a an API Operation using an existing API Operation as a template.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        templateGUID - unique identifier of the metadata element to copy
        apiGUID - unique identifier of the API where the API Operation is located
        templateProperties - properties that override the template
        Returns:
        unique identifier of the new API Operation
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • updateAPIOperation

        void updateAPIOperation​(java.lang.String userId,
                                java.lang.String apiManagerGUID,
                                java.lang.String apiManagerName,
                                java.lang.String apiOperationGUID,
                                boolean isMergeUpdate,
                                APIOperationProperties properties)
                         throws InvalidParameterException,
                                UserNotAuthorizedException,
                                PropertyServerException
        Update the metadata element representing an API Operation.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiOperationGUID - unique identifier of the metadata element to update
        isMergeUpdate - are unspecified properties unchanged (true) or removed?
        properties - new properties for the metadata element
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • removeAPIOperation

        void removeAPIOperation​(java.lang.String userId,
                                java.lang.String apiManagerGUID,
                                java.lang.String apiManagerName,
                                java.lang.String apiOperationGUID,
                                java.lang.String qualifiedName)
                         throws InvalidParameterException,
                                UserNotAuthorizedException,
                                PropertyServerException
        Remove an API Operation.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiOperationGUID - unique identifier of the metadata element to remove
        qualifiedName - unique name of the metadata element to remove
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • createAPIParameterList

        java.lang.String createAPIParameterList​(java.lang.String userId,
                                                java.lang.String apiManagerGUID,
                                                java.lang.String apiManagerName,
                                                java.lang.String apiOperationGUID,
                                                APIParameterListType parameterListType,
                                                APIParameterListProperties properties)
                                         throws InvalidParameterException,
                                                UserNotAuthorizedException,
                                                PropertyServerException
        Create a new metadata element to represent an API Operation's Parameter list. This describes the structure of the payload supported by the API's operation. The structure of this API Operation is added using API Parameter schema attributes. These parameters can have a simple type or a nested structure.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiOperationGUID - unique identifier of an APIOperation
        parameterListType - is this a header, request or response
        properties - properties about the API parameter list
        Returns:
        unique identifier of the new API parameter list
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • createAPIParameterListFromTemplate

        java.lang.String createAPIParameterListFromTemplate​(java.lang.String userId,
                                                            java.lang.String apiManagerGUID,
                                                            java.lang.String apiManagerName,
                                                            java.lang.String templateGUID,
                                                            java.lang.String apiOperationGUID,
                                                            APIParameterListType parameterListType,
                                                            TemplateProperties templateProperties)
                                                     throws InvalidParameterException,
                                                            UserNotAuthorizedException,
                                                            PropertyServerException
        Create a new metadata element to represent a an API Parameter List using an existing API Parameter List as a template.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        templateGUID - unique identifier of the metadata element to copy
        apiOperationGUID - unique identifier of the API where the API Operation is located
        parameterListType - is this a header, request or response
        templateProperties - properties that override the template
        Returns:
        unique identifier of the new API Parameter List
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • updateAPIParameterList

        void updateAPIParameterList​(java.lang.String userId,
                                    java.lang.String apiManagerGUID,
                                    java.lang.String apiManagerName,
                                    java.lang.String apiParameterListGUID,
                                    boolean isMergeUpdate,
                                    APIParameterListProperties properties)
                             throws InvalidParameterException,
                                    UserNotAuthorizedException,
                                    PropertyServerException
        Update the metadata element representing an API ParameterList.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiParameterListGUID - unique identifier of the metadata element to update
        isMergeUpdate - are unspecified properties unchanged (true) or removed?
        properties - new properties for the metadata element
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • removeAPIParameterList

        void removeAPIParameterList​(java.lang.String userId,
                                    java.lang.String apiManagerGUID,
                                    java.lang.String apiManagerName,
                                    java.lang.String apiParameterListGUID,
                                    java.lang.String qualifiedName)
                             throws InvalidParameterException,
                                    UserNotAuthorizedException,
                                    PropertyServerException
        Remove an API Parameter List and all of its parameters.
        Parameters:
        userId - calling user
        apiManagerGUID - unique identifier of software server capability representing the caller
        apiManagerName - unique name of software server capability representing the caller
        apiParameterListGUID - unique identifier of the metadata element to remove
        qualifiedName - unique name of the metadata element to remove
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)
      • getParameterListsForAPIOperation

        java.util.List<APIParameterListElement> getParameterListsForAPIOperation​(java.lang.String userId,
                                                                                 java.lang.String apiOperationGUID,
                                                                                 int startFrom,
                                                                                 int pageSize)
                                                                          throws InvalidParameterException,
                                                                                 UserNotAuthorizedException,
                                                                                 PropertyServerException
        Return the list of API Parameter Lists associated with an API Operation.
        Parameters:
        userId - calling user
        apiOperationGUID - unique identifier of the API Operation to query
        startFrom - paging start point
        pageSize - maximum results that can be returned
        Returns:
        list of metadata elements describing the API Parameter Lists associated with the requested API Operation
        Throws:
        InvalidParameterException - one of the parameters is invalid
        UserNotAuthorizedException - the user is not authorized to issue this request
        PropertyServerException - there is a problem reported in the open metadata server(s)