WO2020093742A1 - 一种api发布方法及装置 - Google Patents

一种api发布方法及装置 Download PDF

Info

Publication number
WO2020093742A1
WO2020093742A1 PCT/CN2019/099041 CN2019099041W WO2020093742A1 WO 2020093742 A1 WO2020093742 A1 WO 2020093742A1 CN 2019099041 W CN2019099041 W CN 2019099041W WO 2020093742 A1 WO2020093742 A1 WO 2020093742A1
Authority
WO
WIPO (PCT)
Prior art keywords
target
api
ccf entity
ccf
domain
Prior art date
Application number
PCT/CN2019/099041
Other languages
English (en)
French (fr)
Inventor
葛翠丽
阿芒哥倪瑞特
杨艳梅
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP19881835.3A priority Critical patent/EP3863312B1/en
Publication of WO2020093742A1 publication Critical patent/WO2020093742A1/zh
Priority to US17/308,414 priority patent/US11533596B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/36Software reuse
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/50Service provisioning or reconfiguring
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/34Network arrangements or protocols for supporting network services or applications involving the movement of software or configuration parameters 
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/30Services specially adapted for particular environments, situations or purposes
    • H04W4/40Services specially adapted for particular environments, situations or purposes for vehicles, e.g. vehicle-to-pedestrians [V2P]

Definitions

  • This application relates to the field of communication technology, and in particular, to an API publishing method and device.
  • APIs application program interfaces
  • 3GPP third generation partnership project
  • CAPIF common API framework
  • the CAPIF system architecture supports one or more common application program interface (CAPIF core) function (CCF) entities, and defines interfaces for multiple CCF entities.
  • a CCF entity usually supports functions such as API release and authentication in an area. Currently, when an API is released, it will only be released to one CCF entity.
  • V2X vehicle-to-everything
  • PLMN public land mobile networks
  • the service coverage of the same V2X application may span PLMN, and even within the same PLMN, a local application can span multiple areas; for interconnection between different PLMNs, and multiple areas within the same PLMN
  • PLMN public land mobile networks
  • the API publishing method provided in the embodiment of the present application can implement publishing of the API to multiple CCF entities.
  • the present application provides an API distribution method and a communication device.
  • the API publishing method may include: the first CCF entity determines the API to be shared; the first CCF entity shares the information of the API to be shared with the target CCF entity of the API to be shared. In this method, the first CCF entity may share the API with other CCF entities, so as to publish the API to multiple CCF entities. In this way, an API can provide calls through AEF entities corresponding to multiple CCF entities, so that API calling entities can discover and obtain APIs through multiple CCF entities.
  • the first CCF entity receives the first API release request, and the first API release request includes API information and API shared information; the first CCF entity issues the request according to the first API, Determine the API to be shared; and, the first CCF entity determines the target CCF entity based on the shared information.
  • the publishing entity determines the shared API and the target CCF entity of the shared API.
  • the sharing information includes at least one of sharing indication information, target CCF entity information, or target domain indication information; wherein, the sharing indication information is used to indicate the sharing of the API to be shared; the target domain indication information is used to indicate the target Domain, the target domain is different from the domain to which the first CCF entity belongs.
  • the sharing information includes sharing instruction information, and the first CCF entity determines the target CCF entity according to the first preset rule; or, the sharing information includes information of the target CCF entity, and the first CCF entity based on the target CCF entity's The information determines the target CCF entity; or, the shared information includes target domain indication information, and the first CCF entity determines the second target CCF entity according to the target domain indication information, where the second target CCF entity is one or more of the target CCF entities.
  • the domain to which the second target CCF entity belongs is different from the domain to which the first CCF entity belongs.
  • the target domain indication information is the identification of the target domain, and the first CCF entity determines the second target CCF entity within the target domain according to the second preset rule; or, the target domain indication information includes the identification of the target domain With the information of the target CCF entity outside the domain, the first CCF entity determines the second target CCF entity in the target domain according to the information of the target CCF entity outside the domain.
  • the sharing information includes sharing range indication information, and the sharing range indication information is used to indicate the sharing range of the API to be shared.
  • the API entity determines the scope of the shared API.
  • the sharing range of the API to be shared is the CCF entity in the domain to which the first CCF entity belongs, and the first CCF entity determines the target CCF entity among the CCF entities in the domain to which the first CCF entity belongs.
  • the sharing range of the API to be shared is a CCF entity outside the domain to which the first CCF entity belongs, and the first CCF entity determines the target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs.
  • the sharing range of the API to be shared includes the CCF entity in the domain to which the first CCF entity belongs, and the CCF entity outside the domain to which the first CCF entity belongs, and the CCF entity in the domain to which the first CCF entity belongs.
  • the first target CCF entity is determined from the entities
  • the second target CCF entity is determined from the CCF entities outside the domain to which the first CCF entity belongs, where the target CCF entity includes the first target CCF entity and the second target CCF entity.
  • the first target CCF entity is one or more of the target CCF entities, the domain of the first target CCF entity is the same as the domain of the first CCF entity; the second target CCF entity is one or more of the target CCF entities, the second The domain to which the target CCF entity belongs is different from the domain to which the first CCF entity belongs.
  • the shared information further includes target domain indication information; where the target domain indication information is used to indicate the target domain to which the target CCF entity belongs.
  • the first CCF entity determines the target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs, including: the first CCF entity determines the target CCF entity among the CCF entities in the target domain.
  • the first CCF entity determines the second target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs, including: the first CCF entity determines the second target CCF entity among the CCF entities in the target domain.
  • the first CCF entity determines the API to be shared according to the third preset rule. Further, according to the fourth preset rule, the target CCF entity is determined. In this implementation, the CCF entity determines the shared API and the target CCF entity of the shared API.
  • the target CCF entity includes a first target CCF entity and / or a second target CCF entity; wherein, the domain to which the first target CCF entity belongs is the same as the domain to which the first CCF entity belongs; the second target CCF entity The domain to which the first CCF entity belongs is different.
  • the first CCF entity shares the information of the API to be shared with the second target CCF entity, where the information of the API to be shared is global information.
  • the information of the API to be shared is global information.
  • the information of the API to be shared includes interface information of the API to be shared, where the interface information is information of a topology hidden entry point.
  • the interface information between different domains is topologically hidden, and the internal topology of the network is not displayed, which can make interaction between entities in different domains more convenient and ensure system security.
  • the present application also provides a communication device, which can implement the API release method described in the first aspect.
  • the device may be a CCF entity or a chip applied to the CCF entity, or may be another device capable of implementing the above API publishing method, which may implement the above method through software, hardware, or executing corresponding software through hardware.
  • the device may include a processor and memory.
  • the processor is configured to support the device to perform the corresponding function in the method of the first aspect.
  • the memory is used to couple with the processor, which stores necessary program instructions and data of the device.
  • the device may also include a communication interface for supporting communication between the device and other devices.
  • the communication interface may be a transceiver or a transceiver circuit.
  • the device may include: a processing module and a sending module.
  • the processing module is used to determine the API to be shared;
  • the sending module is used to share the information of the API to be shared with the target CCF entity of the API to be shared.
  • the device further includes: a receiving module.
  • the receiving module is used to receive the first API release request, including API information and API sharing information; the processing module is specifically used to determine the API to be shared according to the first API release request.
  • the processing module is also used to determine the target CCF entity based on the shared information.
  • the sharing information includes at least one of sharing indication information, target CCF entity information, or target domain indication information; wherein, the sharing indication information is used to indicate the sharing of the API to be shared; the target domain indication information is used to indicate the target Domain, the target domain is different from the domain to which the first CCF entity belongs.
  • the shared information includes sharing instruction information, and the processing module is used to determine the target CCF entity according to the first preset rule; or, the shared information includes information of the target CCF entity, and the processing module is used to determine the target CCF
  • the entity information determines the target CCF entity; or, the shared information includes target domain indication information, and the processing module is used to determine the second target CCF entity according to the target domain indication information, where the second target CCF entity is one or more of the target CCF entities
  • the domain to which the second target CCF entity belongs is different from the domain to which the first CCF entity belongs.
  • the sharing information includes sharing range indication information; the sharing range indication information is used to indicate the sharing range of the API to be shared.
  • the sharing range of the API to be shared is the CCF entity in the domain to which the first CCF entity belongs, and the processing module is used to determine the target CCF entity among the CCF entities in the domain to which the first CCF entity belongs.
  • the sharing range of the API to be shared is a CCF entity outside the domain to which the first CCF entity belongs, and a processing module is used to determine a target CCF entity among CCF entities outside the domain to which the first CCF entity belongs.
  • the sharing range of the API to be shared includes the CCF entity in the domain to which the first CCF entity belongs, and the CCF entity outside the domain to which the first CCF entity belongs, and the processing module is used for the The first target CCF entity is determined in the CCF entity, and the second target CCF entity is determined in the CCF entity outside the domain to which the first CCF entity belongs, where the target CCF entity includes the first target CCF entity and the second target CCF entity.
  • the first target CCF entity is one or more of the target CCF entities, the domain of the first target CCF entity is the same as the domain of the first CCF entity; the second target CCF entity is one or more of the target CCF entities, the second The domain to which the target CCF entity belongs is different from the domain to which the first CCF entity belongs.
  • the shared information further includes target domain indication information; where the target domain indication information is used to indicate the target domain to which the target CCF entity belongs.
  • the processing module determines the target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs, specifically including: the processing module determines the target CCF entity among the CCF entities in the target domain.
  • the processing module determines the second target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs, specifically including: the processing module determines the second target CCF entity among the CCF entities in the target domain.
  • the target domain indication information is an identification of the target domain
  • the processing module is specifically configured to determine the second target CCF entity in the target domain according to the second preset rule; or, the target domain indication information includes the target domain's The identifier and the information of the target CCF entity outside the domain.
  • the processing module is specifically configured to determine the second target CCF entity in the target domain according to the information of the target CCF entity outside the domain.
  • the processing module is specifically used to determine the API to be shared according to the third preset rule.
  • the processing module is specifically used to determine the target CCF entity according to the fourth preset rule.
  • the target CCF entity includes a first target CCF entity and / or a second target CCF entity; wherein, the domain to which the first target CCF entity belongs is the same as the domain to which the first CCF entity belongs; the second target CCF entity The domain to which the first CCF entity belongs is different.
  • the sending module shares the information of the API to be shared with the target CCF entity of the API to be shared, which specifically includes: the sending module shares the information of the API to be shared with the second target CCF entity, wherein the information of the API to be shared For global information.
  • the information of the API to be shared includes interface information of the API to be shared, wherein the interface information is information of a topology hidden entry point.
  • this application provides an API publishing method and device.
  • the method may include: the API publishing entity determines API information and API sharing information, wherein the sharing information is used to instruct the first CCF entity to share the API; the API publishing entity sends the first CCF entity A first API release request, where the first API release request includes API information and API shared information.
  • the API publishing entity may indicate whether to share the API in the API publishing request message sent to the first CCF entity, and the first CCF entity may share the information of the API to be shared with other CCF entities according to the sharing information, thereby implementing the API publishing To multiple CCF entities. In this way, the API calling entity can discover and obtain the API through multiple CCF entities.
  • the sharing information includes at least one of sharing indication information, target CCF entity information, or target domain indication information; wherein, the sharing indication information is used to indicate the sharing of the API to be shared; the target domain indication information is used to indicate the target Domain, the target domain is different from the domain to which the first CCF entity belongs.
  • the sharing information includes sharing range indication information; the sharing range indication information is used to indicate the sharing range of the API to be shared.
  • the shared information further includes target domain indication information, and the target domain indication information is used to indicate the target domain to which the target CCF entity belongs.
  • the target domain indication information is the identification of the target domain; or, the target domain indication information includes the identification of the target domain and the out-of-domain target CCF entity information. Information about the target CCF entity in the target domain.
  • the present application also provides a communication device, which can implement the API release method described in the second aspect.
  • the device may be an API issuing entity or a chip applied to the API issuing entity, or may be another device capable of implementing the above API issuing method, which may implement the above method through software, hardware, or executing corresponding software through hardware.
  • the device may include a processor and memory.
  • the processor is configured to support the device to perform the corresponding function in the method of the second aspect.
  • the memory is used to couple with the processor, which stores necessary program instructions and data of the device.
  • the device may also include a communication interface for supporting communication between the device and other devices.
  • the communication interface may be a transceiver or a transceiver circuit.
  • the device may include: a processing module and a sending module.
  • the processing module is used to determine the information of the API and the shared information of the API, the shared information is used to instruct the first CCF entity to share the API;
  • the sending module is used to send the first API release request to the first CCF entity, wherein, the first The API release request includes API information and API shared information.
  • the sharing information includes at least one of sharing indication information, target CCF entity information, or target domain indication information; wherein, the sharing indication information is used to indicate the sharing of the API to be shared; the target domain indication information is used to indicate the target Domain, the target domain is different from the domain to which the first CCF entity belongs.
  • the sharing information includes sharing range indication information; the sharing range indication information is used to indicate the sharing range of the API to be shared.
  • the shared information further includes target domain indication information, and the target domain indication information is used to indicate the target domain to which the target CCF entity belongs.
  • the target domain indication information is the identification of the target domain; or, the target domain indication information includes the identification of the target domain and the out-of-domain target CCF entity information, where the out-of-domain target CCF entity information is used to indicate that Information about the target CCF entity in the target domain.
  • the present application also provides a computer-readable storage medium having instructions stored therein, which when executed on a computer, causes the computer to perform the method described in any one of the above aspects.
  • the present application also provides a computer program product containing instructions that, when run on a computer, causes the computer to perform the method described in any one of the above aspects.
  • the present application also provides a chip system.
  • the chip system includes a processor, and may further include a memory, for implementing the method described in any one of the above aspects.
  • the present application provides a communication system, including the above-mentioned device for implementing the method of the first aspect, and the above-mentioned device for implementing the method of the second aspect.
  • FIG. 1 is a schematic diagram of a system architecture applicable to the technical solution provided by the embodiments of the present application;
  • FIG. 2 is a schematic structural diagram of a communication device to which the technical solutions provided by the embodiments of the present application are applicable;
  • FIG. 3 is a schematic diagram 1 of an API publishing method provided by an embodiment of this application.
  • FIG. 4 is a schematic diagram 2 of an API publishing method provided by an embodiment of the present application.
  • FIG. 5 is a schematic diagram 3 of an API publishing method provided by an embodiment of the present application.
  • 5A is a schematic diagram 4 of an API publishing method provided by an embodiment of the present application.
  • FIG. 6 is a schematic structural diagram 1 of a communication device according to an embodiment of the present application.
  • FIG. 7 is a second structural diagram of a communication device according to an embodiment of the present application.
  • FIG. 8 is a third structural diagram of a communication device according to an embodiment of the present application.
  • the technical solution provided by this application can be applied to the CAPIF system architecture shown in FIG. 1.
  • the system architecture may include API invoker entities, CCF entities, API opening (API exposing function, AEF) entities, API publishing (API publishing function, APF) entities, and API management (API management) functions, APIMF entities, etc. .
  • the API calling entity is a logical function entity that calls, accesses, and uses the API, and may also be called an API caller. Its supported capabilities can include: authentication of API calling entities, for example, authentication by identifying API calling entities and other information; mutual authentication with CAPIF; obtaining authorization before accessing APIs; discovering APIs; calling APIs, etc.
  • the API calling entity may be a third-party application that has signed a service agreement with the PLMN operator, or it may be an application of the PLMN operator. For example, machine-to-machine (M2M) applications, Internet of Vehicles (IoT) applications, V2X applications, etc.
  • the CCF entity is used to provide CAPIF API. Its supported capabilities can include: authentication of API calling entities based on the identity and other information of API calling entities; mutual authentication with API calling entities; providing authorization to API calling entities before API calling entities access APIs; publishing, storing, and supporting APIs Discovery; PLMN operator-based policies are responsible for API access control; store API call logs and provide them to authorized entities; API-based logs for billing; detect API calls; API call entity registration; store configuration policies; Audit of call logs, etc.
  • the AEF entity is used to provide API, and it is also the entry point for API calling entity to call API. Its supported capabilities may include: authentication of API calling entities based on the identity of the API calling entity and other information provided by the CCF entity; confirmation of authorization provided by the CCF; synchronization of API logs to the CCF entity, etc.
  • the APF entity provides the API publishing function so that the API calling entity can discover the API. Its supported capabilities can include: publishing API functions.
  • the APIMF entity provides management functions for the API. Its supported capabilities may include: auditing API call logs provided from CCF entities; monitoring events reported by CCF entities; configuring API provider policies to APIs; detecting API status; registering API call entities.
  • an API provider domain may include an APF entity, an APIMF entity, and one or more AEF entities.
  • the system architecture may include one or more trust domains.
  • a trust domain may be a PLMN network domain.
  • the trust domain A is the PLMN network domain of the operator A
  • the trust domain B is the PLMN network of the operator B. Domain; the entities of a trust domain are controlled by the same operator and provide sufficient security protection. According to the granularity of security control, the same operator can also be divided into different trust domains.
  • a trust domain may be a network corresponding to a region in a PLMN network domain.
  • trust domain A is the PLMN network of operator Z in the northwest region
  • trust domain B is the PLMN network of operator Z in the Beijing region.
  • a trusted domain is called a domain.
  • a domain may include API calling entities, AEF entities, APF entities, APIMF entities, and one or more CCF entities.
  • API Open Entity 1 API Publishing Entity 1, API Management Entity 1, CCF Entity 1, API Open Entity 2, API Publishing Entity 2, API Management Entity 2, CCF Entity 2, and API Calling Entity 1 belong to the trust domain A;
  • API Open entity 3, API publishing entity 3, API management entity 3, CCF entity 3, and API calling entity 2 belong to trust domain B.
  • the AEF entity in a trust domain can communicate with the CCF entity through the CAPIF-3 interface
  • the APF entity can communicate with the CCF entity through the CAPIF-4 interface
  • the APIMF entity can communicate with the CCF entity through the CAPIF-5 interface.
  • API calling entities in a trusted domain can call APIs in the trusted domain through the CAPIF-2 interface.
  • API calling entities that do not belong to a trusted domain (that is, outside the trusted domain) can call APIs that belong to the trusted domain through the CAPIF-2e interface.
  • API calling entity 1 has a contractual relationship with operator A
  • the PLMN network domain of operator A is trust domain A, that is, API calling entity 1 belongs to trust domain A, that is, API calling entity 1 is in trust domain A.
  • Each trust domain can have a top-level (domain boundary) CCF entity, and can also have 0 or more low-level CCF entities connected to it; and, the top-level CCF entity of a trust domain can also be connected with other trusts
  • the top-level CCF entities of the domain are connected, and the CCF entities of different trust domains communicate through CAPIF-6e.
  • CAPIF-6 interface between two CCFs within the CAPIF of the same trust domain
  • CAPIF-6e can support CAPIF3, CAPIF4 and CAPIF5 interface functions of cross-system security.
  • each functional entity in FIG. 1 may be implemented by one physical device, or may be implemented by multiple physical devices together, or may be a logical function module in a physical device, which is not specifically limited in this embodiment of the present application .
  • the API calling entity, AEF entity, APF entity, APIMF entity or CCF entity may be a device in a PLMN network; for example, it may be a device in a 4G or 5G mobile communication system.
  • the API calling entity, AEF entity, APF entity, APIMF entity or CCF entity may run in the terminal device or in the network device.
  • the API call entity may be a mobility management (MME) entity, a radio access network (RAN) device, a policy and charging rule function in a 4G communication system , PCRF) entity, home subscriber server (HSS), broadcast-multicast service center (broadcast-multicast service center, BM-SC), service-call session control entity (service-call session control function, S-CSCF ) Or application (application, function, AF) entity, etc .; API calling entity can also be the access and mobility management function (AMF) entity, session management function (session management function, SMF) in the 5G communication system Entity, unified data management (UDM) entity, user plane function (UPF) entity, policy control function (PCF) entity, authentication server function (AUSF) entity ⁇ Network opening (network exposure function , NEF) entity, network slice selection (network slice selection function, NSSF) entity, network function repository (network function repository function, NRF) entity or AF entity, etc.
  • MME mobility management
  • RAN radio access network
  • the AEF entity can run in a 4G network service capability (service capability, function, SCEF) entity.
  • the AEF entity can also run in the NEF of the 5G network, or it can be an AMF entity, SMF entity, UDM entity, PCF entity, NRF entity, AUSF entity, NSSF entity.
  • the CCF entity can be independently deployed in an independent network entity; or the CCF entity can also be deployed in the SCEF of a 4G network or NEF of a 5G network together with an entity in the API provisioning domain.
  • the API calling entity, AEF entity, APF entity, APIMF entity, and CCF entity in FIG. 1 can all be implemented by the apparatus 200 in FIG. 2.
  • FIG. 2 is a schematic diagram of a hardware structure of an apparatus 200 provided by an embodiment of the present application.
  • the device 200 includes at least one processor 201, a communication bus 202, a memory 203, and at least one communication interface 204.
  • the processor 201 may be a general-purpose central processing unit (central processing unit, CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more of which are used to control the execution of the program program of this application integrated circuit.
  • CPU central processing unit
  • ASIC application-specific integrated circuit
  • the communication bus 202 may include a path to transfer information between the aforementioned components.
  • Communication interface 204 using any device such as a transceiver, for communicating with other devices or communication networks, such as Ethernet, wireless access network (RAN), wireless local area networks (WLAN), etc. .
  • RAN wireless access network
  • WLAN wireless local area networks
  • the memory 203 may be read-only memory (ROM) or other types of static storage devices that can store static information and instructions, random access memory (random access memory, RAM), or other types of information and instructions that can be stored
  • the dynamic storage device can also be electrically erasable programmable read-only memory (electrically erasable programmable-read-only memory (EEPROM), read-only compact disc (compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (Including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or can be used to carry or store desired program code in the form of instructions or data structures and can be used by a computer Access to any other media, but not limited to this.
  • the memory may exist independently and be connected to the processor through the bus. The memory can also be integrated with the processor.
  • the memory 203 is used to store application program code for executing the solution of the present application, and is controlled and executed by the processor 201.
  • the processor 201 is used to execute the application program code stored in the memory 203, so as to implement the API issuing method provided by the following embodiments of the present application.
  • the processor 201 may include one or more CPUs, such as CPU0 and CPU1 in FIG. 2.
  • the apparatus 200 may include multiple processors, such as the processor 201 and the processor 208 in FIG. 2. Each of these processors can be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor.
  • the processor here may refer to one or more devices, circuits, and / or processing cores for processing data (eg, computer program instructions).
  • the apparatus 200 may further include an output device 205 and an input device 206.
  • the output device 205 communicates with the processor 201 and can display information in various ways.
  • the output device 205 may be a liquid crystal display (LCD), a light emitting diode (LED) display device, a cathode ray tube (CRT) display device, or a projector. Wait.
  • the input device 206 communicates with the processor 201 and can accept user input in a variety of ways.
  • the input device 206 may be a mouse, a keyboard, a touch screen device, or a sensing device.
  • the above apparatus 200 may be a general communication device or a dedicated communication device.
  • the apparatus 200 may be a desktop computer, a portable computer, a network server, a personal digital assistant (PDA), a mobile phone, a tablet computer, a wireless terminal device, an embedded device, or a device with a similar structure in FIG. .
  • PDA personal digital assistant
  • the embodiment of the present application does not limit the type of the device 200.
  • the CCF entity may publish these APIs to other CCF entities in the domain to which the CCF entity belongs, or publish these APIs to other CCF entities outside the domain of the CCF entity.
  • the process that a CCF entity publishes the acquired API to other CCF entities is called a shared API.
  • the CCF entity that executes the sharing process is the source CCF entity
  • the one or more CCF entities that receive the shared API are the target CCF entities that share the API .
  • the CAPIF system architecture may include multiple domains, and each domain may include one or more CCF entities.
  • the domain to which the target CCF entity belongs is the target domain of the source CCF entity sharing API.
  • CCF entity 1 belongs to trust domain A
  • CCF entity 3 belongs to trust domain B. If CCF entity 1 shares the API to CCF entity 3, trust domain B is the target domain for CCF entity 1 to share the API.
  • words “first” and “second” do not limit the number and the execution order, and the words “first” and “second” do not necessarily limit the difference. This is not specifically limited.
  • words such as “exemplary” or “for example” are used as examples, illustrations or explanations. Any embodiments or design solutions described as “exemplary” or “for example” in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or design solutions. Rather, the use of words such as “exemplary” or “for example” is intended to present related concepts in a specific manner.
  • the embodiments of the present application provide an API publishing method. As shown in FIG. 3, the method may include the following steps:
  • the first CCF entity determines the API to be shared.
  • the API provider can publish the API on the AEF entity to the CCF entity through the API publishing entity.
  • the API calling entity can discover and obtain the API provided by the AEF entity through the CCF entity, and then call the API.
  • Calling the API can also be understood as accessing the API.
  • the API calling entity can obtain required resources and services, such as broadcast transmission resources and video acceleration services.
  • the first CCF entity may be a CCF entity in the CAPIF system architecture, and the API publishing entity of the API provider is connected to the first CCF entity through a CAPIF-4 interface.
  • the first CCF entity is a CCF entity at a domain boundary .
  • the first CCF entity is CCF entity 1 in FIG. 1.
  • the first CCF entity may share it with the target CCF entity, so that the API calling entity may discover and obtain the shared API through the target CCF entity.
  • the first CCF entity determines the API to be shared. In an implementation manner, as in Embodiment 2 or Embodiment 4, the first CCF entity receives the first API release request message from the API release entity, and determines the API to be shared according to the first API release request message. In another implementation manner, as in Embodiment 3, the first CCF entity determines the API to be shared according to the third preset rule.
  • the first CCF entity shares the information of the API to be shared with the target CCF entity of the API to be shared.
  • the first CCF entity determines the target CCF entity to share the API.
  • the first CCF entity receives the first API release request message from the API release entity, and determines the target CCF entity of the API to be shared according to the first API release request message.
  • the first CCF entity determines the target CCF entity of the API to be shared according to the fourth preset rule.
  • the first CCF entity shares the information of the API to be shared with the target CCF entity of the API to be shared.
  • the information of the API may include the identifier of the API, the type of the API or the interface information of the API, and so on.
  • the logo of the API is used to identify the API.
  • the logo of the API may be the number of the API (such as: letters, numbers, or special symbols, or a free combination of at least two of letters, numbers, and special symbols), It can also be the name of the API, the index of the API or the uniform resource identifier (URL) of the API, etc .
  • the type of the API can be V2X business, IoT business or M2M business, etc .
  • the interface information of the API can be AEF entity Fully qualified domain name (FQDN), internet protocol (IP) address of AEF entity, or port number of AEF entity, or IP address and port number of AEF entity, etc.
  • FQDN Fully qualified domain name
  • IP internet protocol
  • API information is shown in Table 1:
  • the API information may be the only information in the domain, for example, the API identifier is the only identifier in the domain; if the domain to which the target CCF entity belongs is the first
  • the API information may be global information.
  • the API identifier is a globally unique identifier.
  • the global information can be understood as the API information that can be recognized by all domains in the CAPIF system.
  • the global address can be understood as an address that can be recognized by all domains in the CAPIF system.
  • the first CCF entity may share the API with other CCF entities, so as to publish the API to multiple CCF entities.
  • the API calling entity can discover and obtain the API through multiple CCF entities.
  • the embodiments of the present application provide an API publishing method. As shown in FIG. 4, the method may include the following steps:
  • the API publishing entity determines the information of the API and the shared information of the API.
  • the API publishing entity determines the information of the API, which is the API to be shared, and determines the shared information of the API.
  • the API publishing entity may be an APF entity, or the API publishing entity may also be an APIMF entity.
  • the API publishing entity may also be another entity in the CAPIF system architecture, which is not limited in this embodiment of the present application.
  • an API publishing entity is an APF entity for example.
  • the API publishing entity receives the user's instruction (for example, the user selects the API to be published and the target CCF entity of the API to be released through the human-computer interaction operation page), and obtains the API to be shared and the target CCF entity of the API to be shared .
  • the API publishing entity may determine the API to be shared and the target CCF entity of the API to be shared according to the fifth preset rule.
  • the fifth preset rule may be the mapping relationship between the commercial contract information and the released target CCF entity (which may also be understood as the mapping relationship between the type of API and the domain of the target CCF entity), or the type of API, or the API The mapping relationship between the type and the published target CCF entity (it can also be understood as the mapping relationship between the API type and the logical domain or geographic area of the target CCF entity), etc.
  • operator B and operator A have a contract for sharing the API, that is, for any API of operator A, operator B can obtain and use the API.
  • the API issuing entity of the operator A determines to publish the API to the trust domain corresponding to the operator B according to the contract information shared with the API of the operator B (exemplarily, CCF entity 3 in FIG. 1).
  • the fifth preset rule may be to share the V2X type API to CCF3 and the IoT type API to CCF2.
  • API1 is a V2X type API
  • APF entity 1 determines to share API1 to CCF entity 3
  • API2 is an IoT type API
  • APF entity 1 determines to share API2 to CCF entity 2.
  • the API release 1 entity may also determine the target CCF entity sharing the API according to other rules, which is not limited in the embodiments of the present application.
  • the API publishing entity publishes the API to the CCF entity connected to the API publishing entity through the CAPIF-4 interface (referred to as the CCF entity corresponding to the API publishing entity); at this time, the API publishing entity does not decide whether to share
  • the API is determined by the CCF entity corresponding to the API publishing entity whether to share the API.
  • the API publishing entity sends a third API publishing request message to the corresponding CCF entity, where the third API publishing request message includes the API ’s information.
  • the third API publishing request message may be a service API publishing request (service API publishing request), or a service API configuration request (service API configuration request).
  • the API publishing entity sends the API information to the CCF entity corresponding to the API publishing entity. For example, in FIG. 1, the API publishing entity 1 sends API1, API2, and API3 information to the CCF entity 1. At this time, the API publishing entity may not generate the API shared information or send the API shared information to the CCF entity.
  • the API publishing entity determines whether to share the API. If the API publishing entity determines that sharing of the API is prohibited, in one example, the API publishing entity sends the information of the API and the indication of prohibiting sharing of the API to the first CCF entity; in another example, the API publishing entity only sends If the information of the API is sent to the first CCF entity, it means that sharing of the API is prohibited. If the API publishing entity determines to share the API, the sharing information of the API to be shared is determined, wherein the sharing information of the API is used to instruct the first CCF entity to share the API to be shared, and the sharing information may include sharing indication information, a target CCF entity in the domain At least one of information or target domain indication information.
  • the sharing indication information is used to indicate the sharing of the API to be shared;
  • the target domain indication information is used to indicate the target domain, which is different from the domain to which the first CCF entity belongs;
  • the target CCF entity information within the domain is used to indicate that the API to be shared is in the first CCF Information about the target CCF entity in the domain to which the entity belongs.
  • the sharing prohibition API indication information and the sharing indication information can be represented by different values of a parameter; for example, the parameter value is 0, which means that sharing is prohibited; the parameter value is 1, which means sharing; parameters A value of 2 indicates that it is not specified whether to share; or, the indication information for prohibiting sharing API and the sharing indication information can also be implemented using different parameters.
  • the target CCF entity information in the domain may be the CCF entity identifier, FQDN domain name, IP address or IP address and port number, or URL, etc.
  • the target domain indication information may be the identification of the target domain, such as PLMN ID, domain name (such as domain.com); or, the target domain indication information may also include the identification of the target domain and the out-of-domain target CCF entity information, where the out-of-domain target CCF entity information It can be the identity of the CCF entity, which can be the FQDN domain name, IP address, or IP address and port number, or URL, etc.
  • the shared information may also include information of the target CCF entity.
  • the information of the target CCF entity may be the ID of the CCF entity, the FQDN domain name, the IP address or the IP address and port number, or the URL.
  • sharing indication information is shared indication information
  • shared information is target CCF entity information in the domain
  • shared information is target domain indication information
  • shared information includes shared indication information and target CCF entity information in the domain
  • shared information includes shared indication information and target domain indication information
  • shared information includes shared indication information, target CCF entity information and target domain indication information within the domain.
  • the information of the target CCF entity may appear alone, or may appear in combination with the sharing indication information, the target CCF entity information in the domain, or the target domain indication information, which is not limited in the embodiments of the present application.
  • the trust domain A is the PLMN network domain of the operator A
  • the CCF entity 1 is the CCF entity deployed by the operator A in the Xi’an area, and is used to manage the API provided by the AEF entity in the Xi’an area.
  • Operator A deploys CCF entities in Ningxia to manage APIs provided by AEF entities in Ningxia.
  • API release entity 1 is operator A in Xi’an
  • API release entity 2 is operator A in Ningxia
  • trust domain B It is the PLMN network domain of operator B.
  • API publishing entity determines to publish API1 to CCF entity 1; determines to share API2 to Ningxia region, then determines to publish API2 to CCF entity 1, and CCF entity 1 to CCF entity 2; determines to release API3 For the PLMN network domain shared to Ningxia region and operator B, it is determined to release API3 to CCF entity 1, and CCF entity 1 to CCF entity 2 and CCF entity 3; in turn, API publishing entity 1 may determine not to share API1 , Specify that the API to be shared includes API2 and API3.
  • the API publishing entity determines that the sharing information is sharing indication information, and the sharing indication information instructs the first CCF entity (CCF entity 1) to share the APIs to be shared (API2 and API3), and The CCF entity determines the target CCF of the shared API.
  • the API publishing entity determines that the target CCF entity sharing API2 is CCF entity 2, and determines that the shared information includes information of the target CCF entity in the domain, where the target CCF entity information in the domain includes CCF entity 2 Information.
  • the API publishing entity determines that the target CCF entity sharing API2 is CCF entity 2, and determines that the shared information includes information of the target CCF entity, that is, information including CCF entity 2.
  • the API publishing entity determines that the target CCF entities sharing API3 include CCF entity 2 and CCF entity 3; and determines that the shared information includes target CCF entity information and target domain indication information in the domain, where In the domain, the target CCF entity information includes information of the CCF entity 2, and the target domain indication information indicates the trusted domain B (the domain to which the CCF entity 3 belongs).
  • the API publishing entity determines that the target CCF entities sharing API3 include CCF entity 2 and CCF entity 3, and determines that the shared information includes information of the target CCF entities (CCF entity 2 and CCF entity 3).
  • the trusted domain A in FIG. 1 is the PLMN network domain of operator A
  • the CCF entity 1 is the top-level (also called domain boundary) CCF entity deployed by operator A, which is used to manage operator A.
  • API and other CCF entities of the entire network domain CCF entity 2 is a CCF entity deployed by operator A in Ningxia, used to manage APIs provided by AEF entities in Ningxia
  • trust domain B is the PLMN network domain of operator B
  • CCF Entity 3 is the top-level (also called domain boundary) CCF entity of operator B's PLMN network domain, which is used to manage API of operator B's entire network domain and other CCF entities in the domain.
  • API publishing entity 2 in Ningxia determines that API2 needs to be shared with the entire network of operator A, and then publishes API2 to CCF entity 2, and CCF entity 2 publishes API2 to CCF entity 1; API publishing entity 2 in Ningxia determines API3 To share the PLMN network domain of operator A and the PLMN network domain of operator B, API3 is released to CCF entity 2, and CCF entity 2 releases API3 to CCF entity 1 and CCF entity 3; then, API release entity 2 It can be determined that the APIs to be shared are API2 and API3.
  • the API publishing entity determines that the sharing information is sharing indication information, and the sharing indication information instructs the first CCF entity (CCF entity 2) to share the APIs to be shared (API2 and API3).
  • the API publishing entity determines that the target CCF entity sharing API2 is CCF entity 1, and determines that the shared information includes information of the target CCF entity in the domain, where the target CCF entity information in the domain includes CCF entity 1. Information. In some examples, the API publishing entity (API publishing entity 2) determines that the target CCF entity sharing API2 is CCF entity 1, and determines that the shared information includes information of the target CCF entity, that is, information including CCF entity 1.
  • the API publishing entity determines that the target CCF entity sharing API3 includes CCF entity 1 and CCF entity 3; and determines that the shared information includes target CCF entity information and target domain indication information in the domain, where In the domain, the target CCF entity information includes information of the CCF entity 1, and the target domain indication information indicates the trusted domain B (the domain to which the CCF entity 3 belongs).
  • the API publishing entity determines that the target CCF entities sharing API3 include CCF entity 1 and CCF entity 3, and determines that the shared information includes information of the target CCF entities (CCF entity 2 and CCF entity 3).
  • the API publishing entity sends a first API publishing request to the first CCF entity.
  • the API publishing entity sends a first API publishing request to the first CCF entity, where the first API publishing request includes API information and API shared information.
  • the first API release request message may be a service API release request (service API publishing request), or a service API configuration request (service API configuration request).
  • a first API release request includes information about an API and shared information about the API.
  • the first API release request includes API1 information and API1 shared information.
  • the first CCF entity shares API1 according to the shared information of API1, and the API to be shared is API1.
  • a first API release request includes information of multiple APIs and shared information corresponding to each API, respectively.
  • the first API release request includes API1 information and API1 shared information, API2 information and API2 shared information, API3 information and API3 shared information.
  • the first CCF entity shares each API according to the shared information of each API, for example, the first CCF entity shares API1 according to the shared information of API1, API2 according to the shared information of API2, and API3 according to the shared information of API3.
  • the APIs to be shared are API1, API2 and API3.
  • a first API release request includes information of multiple APIs and a piece of shared information corresponding to the multiple APIs.
  • the first API release request includes API1 information, API2 information, API3 information, and shared information, and the first CCF entity shares API1, API2, and API3 according to the shared information.
  • the APIs to be shared are API1, API2 and API3.
  • the information of the API may include shared information of the API, that is, the shared information of the API may be used as an attribute of the API.
  • the information of the API may include the identification of the API, the type of the API, and the shared information of the API.
  • the information of the API and the shared information of the API may be separate information. This embodiment of the present application does not limit this.
  • the embodiment of the present application takes an example in which a first API release request includes information of one API and shared information of the API.
  • a first API release request includes information of one API and shared information of the API.
  • the technical solution that the first API release request includes information of one API and the sharing information of the API is also applicable to a first API release request including information of multiple APIs and sharing corresponding to each API respectively
  • the information and a scenario where a first API release request includes information of multiple APIs and a shared information corresponding to the multiple APIs will not be described in detail in the embodiments of the present application.
  • the first CCF entity receives the first API release request.
  • the first CCF entity may save the received API information.
  • the first CCF entity sends a first API release response message to the API release entity.
  • the first CCF entity sends a first API release response message to the API release entity.
  • the first API release response message may include release result indication information, used to indicate API release success or API release failure.
  • the API publishing response message may be a service API publishing response (service API publishing response), or a service API configuration response (service API configuration response).
  • the API publishing entity receives the first API publishing response message.
  • the API publishing entity may indicate whether to share the API in the API publishing request message sent to the first CCF entity, and may further indicate the target CCF of the API to be shared. In this way, the first CCF entity The information of the API to be shared can be shared with other CCF entities according to the shared information, so that the API can be published to multiple CCF entities. In this way, the API calling entity can discover and obtain the API through multiple CCF entities.
  • the embodiments of the present application provide an API publishing method. As shown in FIG. 5, the method may include the following steps:
  • the first CCF entity determines the API to be shared and the target CCF entity of the API to be shared.
  • the first CCF entity determines the API to be shared and the target CCF entity of the API to be shared, where the target CCF entity may include the first target CCF entity and / or the second target CCF entity, where the domain to which the first target CCF entity belongs and the first The domain to which a CCF entity belongs is the same, and the domain to which the second target CCF entity belongs is different from the domain to which the first CCF entity belongs.
  • the first CCF entity determines the API to be shared and the target CCF entity of the API to be shared according to the received first API release request.
  • the first API release request includes API information and shared information.
  • the first CCF entity determines the API to be shared according to the API information and the sharing information.
  • the sharing information of the API is included in the first API publishing request, it is determined that the API indicated by the information of the API in the first API publishing request is the API to be shared.
  • the first CCF entity determines the API to be shared according to the API information in the first API release request and the sixth preset rule.
  • the sixth preset rule may include determining the API to be shared according to the mapping relationship between the commercial contract information and the released target CCF entity, or according to the type of API, or according to the type of API, or according to the API type and the released target CCF The mapping relationship of the entities determines the API to be shared, etc.
  • the first CCF entity may also adopt other methods, for example, determining the API to be shared according to other preset rules, which is not limited in this embodiment of the present application.
  • the first CCF entity determines the target CCF entity of the API to be shared according to the sharing information.
  • the sharing information is sharing indication information
  • the first CCF entity determines the target CCF entity according to the first preset rule.
  • the first preset rule may include determining the target CCF entity sharing the API according to the mapping relationship between the commercial contract information and the published target CCF entity (which may also be understood as the mapping relationship between the type of API and the domain of the target CCF entity), Or according to the mapping relationship between the API type and the published target CCF entity (it can also be understood as the mapping relationship between the API type and the logical domain or geographical area of the target CCF entity), the target CCF entity sharing the API, etc., is determined.
  • the first CCF entity may also adopt other methods, for example, determining the target CCF entity of the API to be shared according to other preset rules, which is not limited in this embodiment of the present application.
  • the shared information includes target CCF entity information in the domain, (for example, the shared information is target CCF entity information in the domain, or the shared information is sharing indication information and target CCF entity information in the domain), and the first CCF entity is based on the target in the domain
  • the CCF entity information determines the first target CCF entity.
  • the target CCF entity information in the domain includes information of CCF entity 2, and the first CCF entity determines that the first target CCF entity includes CCF entity 2.
  • the shared information includes target domain indication information (for example, the shared information is target domain indication information; or, the shared information includes shared indication information and target domain indication information), and the first CCF entity uses the target domain indication information Determine the second target CCF entity.
  • the target domain indication information is the identifier of the target domain
  • the first CCF entity determines the second target CCF entity in the target domain according to the second preset rule.
  • the second preset rule is that the target CCF entity is a CCF entity at the domain boundary of the target domain.
  • the target domain indication information is the identifier of the trusted domain B in FIG.
  • the CCF entity at the domain boundary of the trusted domain B is the CCF entity 3, and the first CCF entity determines that the second target CCF entity includes the CCF entity 3.
  • the target domain indication information includes the identification of the target domain and the information of the target CCF entity outside the domain.
  • the first CCF entity determines the second target CCF entity in the target domain according to the information of the target CCF entity outside the domain.
  • the identifier of the target domain is the identifier of the trusted domain B in FIG. 1, the information of the target CCF entity outside the domain includes information of the CCF entity 3, and the first CCF entity determines that the second target CCF entity includes the CCF entity 3 in the trusted domain B.
  • the shared information includes sharing indication information, target CCF entity information in the domain, and target domain indication information; the first CCF entity determines the first target CCF entity based on the target CCF entity information in the domain, and determines the first target CCF entity according to the target domain indication information.
  • the sharing indication information is a numerical value, and the first CCF entity determines the target CCF entity according to the value of the sharing indication information. For example, if the sharing indication information is "00", it means that the API to be shared is shared with the CCF entity in the domain to which the first CCF entity belongs.
  • the first CCF entity determines the CCF entity indicated by the target CCF entity information in the domain as the target CCF entity;
  • the information is "01", indicating that the API to be shared is shared with the CCF entity outside the domain to which the first CCF entity belongs, and the first CCF entity determines the CCF entity indicated by the target domain indication information as the target CCF entity.
  • the shared information includes information of the target CCF entity, (for example, the shared information is information of the target CCF entity, or the shared information is information of the shared indication information and the target CCF entity, or the shared information is shared indication information, (The information of the target CCF entity and the target domain indication information, or the shared information is the information of the target CCF entity and the target domain indication information), the first CCF entity determines the target CCF entity according to the information of the target CCF entity.
  • the first CCF entity may determine the CCF entity indicated by the information of the target CCF entity as the target CCF entity.
  • the target CCF entity may include the first target CCF entity, and / or the second target CCF entity.
  • the information of the target CCF entity includes information of the CCF entity 2, the first CCF entity determines that the target CCF entity includes CCF entity 2; for example, the information of the target CCF entity includes information of the CCF entity 3, and the first CCF entity determines that the target CCF entity includes CCF entity 3; for example, the information of the target CCF entity includes information of the CCF entity 2 and the CCF entity 3, and the first CCF entity determines that the target CCF entity includes the CCF entity 2 and the CCF entity 3.
  • the first CCF entity determines the API to be shared according to the third preset rule; further, the first CCF entity determines the target CCF entity according to the fourth preset rule.
  • the first CCF entity obtains the API to be shared from the locally saved API according to the third preset rule, and determines the target CCF entity of the API to be shared among the locally saved API according to the fourth preset rule.
  • the locally stored API information may be API information saved after the first CCF entity receives the API information received from the API publishing entity.
  • the API information may be obtained by the first CCF entity from the third API release request message of the API release entity.
  • the third preset rule may include determining the API to be shared according to the mapping relationship between the commercial contract information and the published target CCF entity, or determining the pending API according to the type of API or the mapping relationship between the API type and the published target CCF entity Sharing API, etc.
  • the first CCF entity may also adopt other methods, for example, determining the API to be shared according to other preset rules, which is not limited in this embodiment of the present application.
  • the fourth preset rule may include determining the target CCF entity according to the mapping relationship between the commercial contract information and the published target CCF entity, or determining the target according to the API type, or the mapping relationship between the API type and the published target CCF entity CCF entities, etc.
  • the first CCF entity may also adopt other methods, for example, determining the target CCF entity according to other preset rules, which is not limited in this embodiment of the present application.
  • the first CCF entity shares API information with the target CCF entity.
  • the first CCF entity sends a second API release request to the target CCF entity, and the second API release request includes API information.
  • the second API publishing request message may be a service API publishing request (service API publishing request), or a service API configuration request (service API configuration request), or an interconnection API publishing request (interconnection API publishing request).
  • the first CCF entity may modify the information of the API to be shared to global information, and then send the first CCF entity to the second target CCF entity When sharing API information, carry the global information of the API. For example, the first CCF entity changes the local identifier of the API to a global identifier, and changes the local interface address of the API to a global address.
  • the first CCF entity may perform topology hiding on the shared API, that is, for each API to be shared, select an AEF entity as the topology hiding entry Point, replace the interface information of the API to be shared with the information of the AEF entity of the topology hidden entry point.
  • the target CCF entity receives API information.
  • the target CCF entity receives the second API release request, and the second API release request includes API information, and the target CCF entity may save the received API information.
  • the target CCF entity sends a second API release response message to the first CCF entity.
  • the target CCF entity sends a second API release response message to the first CCF entity.
  • the second API release response message may include release result indication information, used to indicate API release success or API release failure.
  • the API publishing response message may be a service API publishing response (service API publishing response), or a service API configuration response (service API configuration response), or an interconnection API publishing response (interconnection API publishing published response).
  • the first CCF entity receives the second API release response message.
  • step S501 of the third embodiment the first CCF entity adopts the first method, that is, the API to be shared and the target CCF entity of the API to be shared are determined according to the received first API release request, then the steps of the second and third embodiments Can be merged.
  • the first CCF entity may send the first API release response message to the API publishing entity at S404; or do not execute S404, and after S505, the first CCF entity receives the second API release response message and then publish to the API The entity sends the first API release response message.
  • each CCF entity may also send a notification message to the API calling entity that subscribes to the API, notifying the API calling entity that there is a new API or an API that the API calling entity is interested in.
  • the first CCF entity may determine to share the API with other CCF entities, so as to publish the API to multiple CCF entities. In this way, the API calling entity can discover and obtain the API through multiple CCF entities.
  • the embodiments of the present application provide an API publishing method. As shown in FIG. 5A, the method may include the following steps:
  • the API publishing entity determines the information of the API and the shared information of the API.
  • the API publishing entity determines the information of the API, which is the API to be shared, and determines the shared information of the API.
  • the API publishing entity may be an APF entity, or the API publishing entity may also be an APIMF entity.
  • the API publishing entity may also be another entity in the CAPIF system architecture, which is not limited in this embodiment of the present application.
  • an API publishing entity is an APF entity for example.
  • the API publishing entity can obtain the API to be shared and the target CCF entity of the API to be shared according to the user's instruction; it can also determine the API to be shared and the target CCF entity of the API to be shared according to a preset rule; I will not repeat them here.
  • the API publishing entity determines whether to share the API. If the API publishing entity determines to share the API, it determines the sharing information of the API to be shared, wherein the sharing information of the API is used to instruct the first CCF entity to share the API to be shared.
  • the sharing information may include sharing range indication information, and the sharing range indication information is used to indicate the sharing range of the API to be shared, wherein the sharing range of the API to be shared may include a CCF entity in the domain to which the first CCF entity belongs, And / or a CCF entity outside the domain to which the first CCF entity belongs.
  • the value of the shared range indication information is 0, which indicates that the sharing range of the API to be shared is a CCF entity in the domain to which the first CCF entity belongs; the value of the shared range indication information is 1, which indicates that the shared range of the API to be shared is, The CCF entity outside the domain to which the first CCF entity belongs; the value of the sharing range indication information is 2, indicating that the sharing range of the API to be shared includes: the CCF entity within the domain to which the first CCF entity belongs and the CCF entity outside the domain to which the first CCF entity belongs.
  • the shared information may further include information of the target CCF entity, including information of the CCF entity in the domain to which the first CCF entity belongs, and / or information of CCF entities outside the domain to which the first CCF entity belongs.
  • the information of the target CCF entity may be the identification of the target CCF entity, FQDN domain name, IP address or IP address and port number, or URL, etc.
  • the sharing range indication information indicates that the sharing range of the API to be shared is the CCF entity in the domain to which the first CCF entity belongs; then the information of the target CCF entity includes information of the CCF entity in the domain to which the first CCF entity belongs.
  • the sharing range indication information indicates that the sharing range of the API to be shared is a CCF entity outside the domain to which the first CCF entity belongs; then the information of the target CCF entity includes information of the CCF entity outside the domain to which the first CCF entity belongs.
  • the sharing range indication information indicates that the sharing range of the API to be shared is the CCF entity in the domain to which the first CCF entity belongs and the CCF entity outside the domain to which the first CCF entity belongs; then the information of the target CCF entity includes the CCF in the domain to which the first CCF entity belongs The information of the entity and the information of the CCF entity outside the domain to which the first CCF entity belongs.
  • the shared information may further include target domain indication information, and the target domain indication information is used to indicate a target domain to which the target CCF entity belongs, which is different from the domain to which the first CCF entity belongs.
  • the target domain indication information may be an identification of the target domain, such as PLMN ID, domain name (such as domain.com); or, the target domain indication information may also include the identification of the target domain and information of the target CCF entity, where the target CCF entity
  • the information can be the identity of the CCF entity, which can be the FQDN domain name, IP address, or IP address and port number, or URL, etc. Sharing range of API to be shared Sharing range of API to be shared Sharing range of API to be shared Sharing range of API to be shared.
  • the trust domain A is the PLMN network domain of the operator A
  • the CCF entity 1 is the CCF entity deployed by the operator A in the Xi’an area, and is used to manage the API provided by the AEF entity in the Xi’an area.
  • Operator A deploys CCF entities in Ningxia to manage APIs provided by AEF entities in Ningxia.
  • API release entity 1 is operator A in Xi’an
  • API release entity 2 is operator A in Ningxia
  • trust domain B It is the PLMN network domain of operator B.
  • API publishing entity determines to publish API1 to CCF entity 1; determines to share API2 to Ningxia region, then determines to publish API2 to CCF entity 1, and CCF entity 1 to CCF entity 2; determines to release API3 For the PLMN network domain shared to Ningxia region and operator B, it is determined to release API3 to CCF entity 1, and CCF entity 1 to CCF entity 2 and CCF entity 3; in turn, API publishing entity 1 may determine not to share API1 , Specify that the API to be shared includes API2 and API3; and, the API publishing entity 1 determines the shared information of API2 and API3.
  • the API publishing entity determines that the shared information is shared range indication information.
  • the sharing range indication information indicates that the sharing range of API2 is a CCF entity in a domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs; at this time, the first CCF entity determines a target CCF entity sharing API2, and the target CCF The entity is a CCF entity in the domain (trust domain A) to which the first CCF entity belongs.
  • the sharing range indication information indicates that the sharing range of API3 is the CCF entity within the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs, and outside the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs.
  • the target CCF entity includes the CCF entity in the domain (trust domain A) to which the first CCF entity belongs, and the first CCF entity (CCF entity 1 ) CCF entities outside the domain (trust domain A).
  • the API publishing entity determines that the shared information is the shared range indication information and the information of the target CCF entity.
  • the API publishing entity (API publishing entity 1) determines that the sharing information corresponding to API2 includes: sharing range indication information indicating that the sharing range of API2 is a CCF entity in the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs; the target The CCF entity information includes CCF entity 2 information.
  • the API publishing entity determines that the sharing information corresponding to API3 includes: sharing range indication information, indicating that the sharing range of API3 is a CCF entity in the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs, And the CCF entity outside the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs; the information of the target CCF entity includes the information of the CCF entity 2 and the information of the CCF entity 3.
  • the API publishing entity determines that the shared information includes target domain indication information.
  • the API publishing entity determines that the sharing information corresponding to API3 includes: sharing range indication information, indicating that the sharing range of API3 is within the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs And the CCF entity outside the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs; the information of the target CCF entity includes information of the CCF entity 2, and the target domain indication information includes information of the trust domain B.
  • the API publishing entity sends a first API publishing request to the first CCF entity.
  • the API publishing entity sends a first API publishing request to the first CCF entity, where the first API publishing request includes API information and API shared information.
  • the first API publishing request includes API information and API shared information.
  • the first CCF entity receives the first API release request.
  • the first CCF entity receives the first API release request, which includes API information and API shared information.
  • the first CCF entity determines the API to be shared according to the API information; and determines that the API indicated by the API information in the first API release request is the API to be shared. For example, if the API information includes API2 information and API3 information, it is determined that the API to be shared includes API2 and API3.
  • the first CCF entity determines the target CCF entity to share the API according to the API sharing information.
  • the target CCF entity may include a first target CCF entity, and / or a second target CCF entity, where the domain of the first target CCF entity belongs to the same domain as the first CCF entity, and the domain of the second target CCF entity belongs to the first The domain to which the CCF entity belongs is different.
  • the shared information is shared range indication information, and the shared range indication information indicates the shared range of the API to be shared; wherein, the shared range of the API to be shared includes CCF entities in the domain to which the first CCF entity belongs, and / or, CCF entities outside the domain to which the first CCF entity belongs.
  • the first CCF entity determines the sharing range of the API to be shared according to the sharing range indication information; if the sharing range is the CCF entity in the domain to which the first CCF entity belongs, the first CCF entity determines the target CCF entity among the CCF entities in the domain to which the first CCF entity belongs If the sharing scope is a CCF entity outside the domain to which the first CCF entity belongs, the first CCF entity determines the target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs; if the sharing scope includes the CCF entity in the domain to which the first CCF entity belongs, and CCF entities outside the domain to which the first CCF entity belongs, the first CCF entity determines the first target CCF entity among the CCF entities within the domain to which the first CCF entity belongs, and determines the second target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs
  • the target CCF entity includes a first target CCF entity and a second target CCF entity.
  • the sharing range of the API to be shared is the CCF entity in the domain to which the first CCF entity belongs, and the first CCF entity determines the target CCF entity in the CCF entity in the domain to which the first CCF entity belongs according to the seventh preset rule, and the target The CCF entity is the first target CCF entity; in some examples, the sharing range of the API to be shared is the CCF entity outside the domain to which the first CCF entity belongs, and the first CCF entity is based on the eighth preset rule in the CCF outside the domain to which the first CCF entity belongs The target CCF entity is determined in the entity, and the target CCF entity is the second target CCF entity; in some examples, the sharing scope of the API to be shared includes the CCF entity in the domain to which the first CCF entity belongs and the CCF entity outside the domain to which the first CCF entity belongs , The first CCF entity determines the first target CCF entity in the CCF entity in the domain to which the first CCF entity belongs according to the seventh preset rule, and determines the
  • the first CCF entity (CCF entity 1) receives the first API release request from the API release entity (API release entity 1), which includes the information of API2 and the value of the corresponding shared range indication information is 0, which means The sharing scope of API2 is the CCF entity in the domain (trust domain A) to which the first CCF entity belongs.
  • the first CCF entity (CCF entity 1) determines the target CCF entity in the trust domain A according to the seventh preset rule.
  • the seventh preset rule is that the target CCF entity includes all CCF entities in the domain (trust domain A) to which the first CCF entity belongs; then it is determined that the target CCF entity includes CCF entity 2.
  • the seventh preset rule is the mapping relationship between the commercial contract information and the published target CCF entity (which can also be understood as the mapping relationship between the type of API and the domain of the target CCF entity), or the type of API, or The mapping relationship between the API type and the released target CCF entity (it can also be understood as the mapping relationship between the API type and the logical domain or geographic area of the target CCF entity), etc.
  • the seventh preset rule may be to share an IoT-type API to CCF2.
  • the first CCF entity determines to share API2 to CCF entity 2, that is, the target CCF entity includes CCF entity 2.
  • the first CCF entity may also adopt other methods, for example, determining the target CCF entity according to other preset rules, which is not limited in this embodiment of the present application.
  • the first API release request further includes information of API3, and the value of the corresponding shared range indication information is 2, indicating that the shared range of API3 includes: the CCF entity within the domain to which the first CCF entity belongs and the domain outside the domain to which the first CCF entity belongs CCF entity.
  • the first CCF entity determines the first target CCF entity in the domain to which the first CCF entity belongs according to the seventh preset rule, and determines the second target CCF entity outside the domain to which the first CCF entity belongs according to the eighth preset rule.
  • the eighth preset rule includes the mapping relationship between the commercial contract information and the published target CCF entity (which may also be understood as the mapping relationship between the type of API and the domain of the target CCF entity), or the type of API, or The mapping relationship between the API type and the released target CCF entity (it can also be understood as the mapping relationship between the API type and the logical domain or geographic area of the target CCF entity), etc.
  • operator B and operator A have a contract for sharing the API, that is, for any API of operator A, operator B can obtain and use the API.
  • the first CCF entity determines to publish the API to the trust domain corresponding to operator B (exemplarily, CCF entity 3 in FIG. 1) according to the contract information shared by the APIs of operator A and operator B.
  • the eighth preset rule may be to share a V2X type API to CCF3.
  • API3 is a V2X type API
  • the first CCF entity determines to share API3 to CCF entity 3.
  • the first CCF entity may also adopt other methods, for example, determining the second target CCF entity according to other preset rules, which is not limited in this embodiment of the present application.
  • the seventh preset rule and the eighth preset rule may be corresponding rules.
  • the seventh preset rule is to determine the target CCF entity according to the type of API
  • the eighth preset rule is to determine according to the type of API Target CCF entity
  • the seventh preset rule and the eighth preset rule can also be non-corresponding rules, for example, the seventh preset rule is to determine the target CCF entity according to the type of API, and the eighth preset rule is based on commercial contract information
  • the mapping relationship with the released target CCF entity determines the target CCF entity. This embodiment of the present application does not limit this.
  • the shared information includes shared range indication information and target CCF entity information.
  • the sharing range indication information indicates that the sharing range of the API to be shared is a CCF entity in the domain to which the first CCF entity belongs, and the first CCF entity determines the CCF entity indicated by the information of the target CCF entity as the target CCF entity, and the target The CCF entity is a CCF entity in the domain to which the first CCF entity belongs.
  • the sharing information corresponding to API2 includes: sharing range indication information, indicating that the sharing range of API2 is a CCF entity in the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs; the information of the target CCF entity includes CCF entity 2 Information; the first CCF entity determines CCF entity 2 as the target CCF entity.
  • the sharing range indication information indicates that the sharing range of the API to be shared is a CCF entity outside the domain to which the first CCF entity belongs, and the first CCF entity determines the CCF entity indicated by the information of the target CCF entity as the target CCF entity.
  • the target CCF entity is a CCF entity outside the domain to which the first CCF entity belongs.
  • the sharing information corresponding to API4 includes: sharing range indication information indicating that the sharing range of API4 is a CCF entity outside the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs; the information of the target CCF entity includes CCF entity 3 information Information; The first CCF entity determines CCF entity 3 as the target CCF entity.
  • the sharing range indication information indicates that the sharing range of the API to be shared is the CCF entity in the domain to which the first CCF entity belongs, and the CCF entity outside the domain to which the first CCF entity belongs, and the first CCF entity uses the information of the target CCF entity
  • the indicated CCF entity is determined to be the target CCF entity.
  • the target CCF entity includes a CCF entity in the domain to which the first CCF entity belongs and a CCF entity outside the domain to which the first CCF entity belongs.
  • the sharing information corresponding to API3 includes: sharing range indication information indicating that the sharing range of API3 is the CCF entity in the domain (trust domain A) to which the first CCF entity (CCF entity 1) belongs, and the first CCF entity (CCF entity 1 ) The CCF entity outside the domain (trust domain A) it belongs to;
  • the information of the target CCF entity includes the information of the CCF entity 2 and the information of the CCF entity 3;
  • the first CCF entity determines the CCF entity 2 as the first target CCF entity and the CCF
  • the entity 3 is determined to be the second target CCF entity, and the target CCF entity includes the first target CCF entity and the second target CCF entity.
  • the shared information further includes target domain indication information, and the target domain indication information is used to indicate the target domain to which the target CCF entity belongs.
  • the first CCF entity determines the second target CCF entity among the CCF entities in the target domain.
  • the target domain indication information is the identifier of the target domain, and the first CCF entity determines the second target CCF entity in the target domain according to the second preset rule.
  • the second preset rule is that the target CCF entity is a CCF entity at the domain boundary of the target domain.
  • the target domain indication information is the identifier of the trusted domain B in FIG. 1, the CCF entity at the domain boundary of the trusted domain B is the CCF entity 3, and the first CCF entity determines that the second target CCF entity includes the CCF entity 3.
  • the target domain indication information includes the identification of the target domain and the information of the target CCF entity outside the domain.
  • the first CCF entity determines the second target CCF entity in the target domain according to the information of the target CCF entity outside the domain.
  • the identifier of the target domain is the identifier of the trusted domain B in FIG. 1
  • the information of the target CCF entity outside the domain includes information of the CCF entity 3
  • the first CCF entity determines that the second target CCF entity includes the CCF entity 3 in the trusted domain B.
  • the information of the CCF entity outside the domain to which the first CCF entity belongs can be indicated by the information of the target CCF entity in the shared information or the target domain indication information in the shared information, which is not performed in the embodiments of the present application limited.
  • the first CCF entity shares API information with the target CCF entity.
  • the method for the first CCF entity to share API information with the target CCF entity can refer to the description of S502, which will not be repeated here.
  • the target CCF entity receives API information.
  • the operation steps after the target CCF entity receives the API information can refer to the description of S503, which will not be repeated here.
  • the target CCF entity sends a second API release response message to the first CCF entity.
  • the first CCF entity receives the second API release response message.
  • each CCF entity may also send a notification message to the API calling entity that subscribes to the API, notifying the API calling entity that there is a new API or an API that the API calling entity is interested in.
  • the first CCF entity may determine to share the API to other CCF entities according to the instruction information of the API publishing entity, so as to publish the API to multiple CCF entities. In this way, the API calling entity can discover and obtain the API through multiple CCF entities.
  • the API issuing entity and the CCF entity include hardware structures and / or software modules corresponding to performing each function.
  • the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed by hardware or computer software driven hardware depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
  • the embodiments of the present application may divide the API publishing entity and the CCF entity according to the above method examples, for example, each functional module may be divided corresponding to each function, or two or more functions may be integrated into one processing module .
  • the above integrated modules may be implemented in the form of hardware or software function modules. It should be noted that the division of the modules in the embodiments of the present application is schematic, and is only a division of logical functions. In actual implementation, there may be another division manner. The following uses an example of dividing each function module corresponding to each function as an example.
  • the apparatus 600 may be a CCF entity, which can implement the function of the first CCF entity in the method provided by the embodiment of the present application; the apparatus 600 may also be capable of supporting the CCF entity An apparatus for applying the function of the first CCF entity in the method provided in the embodiment.
  • the device 600 may be a hardware structure, a software module, or a hardware structure plus a software module.
  • the device 600 may be implemented by a chip system. In the embodiment of the present application, the chip system may be composed of a chip, or may include a chip and other discrete devices. As shown in FIG. 6, the device 600 includes a processing module 601 and a sending module 602.
  • the processing module 601 is used to determine the API to be shared.
  • the sending module 602 is used to share the information of the API to be shared with the target CCF entity of the API to be shared.
  • the device 600 further includes: a receiving module 603.
  • the receiving module 603 is configured to receive a first API release request, including API information and API shared information.
  • the processing module 601 is specifically configured to determine the API to be shared according to the first API release request.
  • the processing module 601 is also used to determine the target CCF entity based on the shared information.
  • the sharing information includes at least one of sharing indication information, target CCF entity information, or target domain indication information; where the sharing indication information is used to indicate sharing of APIs to be shared; the target domain indication information is used to indicate the target domain , The target domain is different from the domain to which the first CCF entity belongs.
  • the shared information includes sharing instruction information, and the processing module 601 is used to determine the target CCF entity according to the first preset rule; or, the shared information includes information of the target CCF entity, and the processing module 601 is used to determine the target The information of the CCF entity determines the target CCF entity; or, the shared information includes target domain indication information, and the processing module 601 is used to determine the second target CCF entity according to the target domain indication information, where the second target CCF entity is one of the target CCF entities or Multiple, the domain to which the second target CCF entity belongs is different from the domain to which the first CCF entity belongs.
  • the sharing information includes sharing range indication information; the sharing range indication information is used to indicate the sharing range of the API to be shared.
  • the sharing range of the API to be shared is a CCF entity in the domain to which the first CCF entity belongs
  • the processing module 601 is used to determine the target CCF entity in the CCF entities in the domain to which the first CCF entity belongs.
  • the sharing range of the API to be shared is a CCF entity outside the domain to which the first CCF entity belongs, and the processing module 601 is used to determine a target CCF entity among CCF entities outside the domain to which the first CCF entity belongs.
  • the sharing range of the API to be shared includes the CCF entity in the domain to which the first CCF entity belongs, and the CCF entity outside the domain to which the first CCF entity belongs, and the processing module 601 is used for the CCF in the domain to which the first CCF entity belongs.
  • the first target CCF entity is determined from the entities
  • the second target CCF entity is determined from the CCF entities outside the domain to which the first CCF entity belongs, where the target CCF entity includes the first target CCF entity and the second target CCF entity.
  • the first target CCF entity is one or more of the target CCF entities, the domain of the first target CCF entity is the same as the domain of the first CCF entity; the second target CCF entity is one or more of the target CCF entities, the second The domain to which the target CCF entity belongs is different from the domain to which the first CCF entity belongs.
  • the shared information further includes target domain indication information; where the target domain indication information is used to indicate the target domain to which the target CCF entity belongs.
  • the processing module 601 determines the target CCF entity among the CCF entities outside the domain to which the first CCF entity belongs, specifically including: the processing module 601 determines the target CCF entity among the CCF entities in the target domain.
  • the processing module 601 determines the second target CCF entity from the CCF entities outside the domain to which the first CCF entity belongs, specifically including: the processing module 601 determines the second target CCF entity from the CCF entities in the target domain.
  • the target domain indication information is an identification of the target domain
  • the processing module 601 is specifically configured to determine the second target CCF entity within the target domain according to the second preset rule; or, the target domain indication information includes the target domain's The identifier and the target CCF entity information outside the domain, the processing module 601 is specifically configured to determine the second target CCF entity in the target domain according to the target CCF entity information outside the domain.
  • the processing module 601 is specifically configured to: determine the API to be shared according to the third preset rule.
  • the processing module 601 is specifically configured to determine the target CCF entity according to the fourth preset rule.
  • the target CCF entity includes a first target CCF entity and / or a second target CCF entity; wherein, the domain to which the first target CCF entity belongs is the same as the domain to which the first CCF entity belongs; the second target CCF entity belongs to The domain is different from the domain to which the first CCF entity belongs.
  • the sending module 602 shares the information of the API to be shared with the target CCF entity of the API to be shared, which specifically includes: the sending module 602 shares the information of the API to be shared with the second target CCF entity.
  • the information is global information.
  • the information of the API to be shared includes interface information of the API to be shared, wherein the interface information is information of an entry point of topology hiding.
  • the processing module 601 can be used to perform at least S301 in FIG. 3 or S501 in FIG. 5 , Or S603 in FIG. 5A, and / or perform other steps described in this application.
  • the sending module 602 may be at least used to perform S302 in FIG. 3, or S404 in FIG. 4, or S502 in FIG. 5, or S604 in FIG. 5A, and / or perform other steps described in this application.
  • the receiving module 603 may be used to perform at least S403 in FIG. 4, or S505 in FIG. 5, or S603, S607 in FIG. 5A, and / or perform other steps described in this application, which will not be repeated here.
  • the apparatus 700 may be an API publishing entity, which can implement the function of the API publishing entity in the method provided by the embodiment of the present application; In the method provided by the embodiment of the present application, a device for releasing API functions of an entity.
  • the device 700 may be a hardware structure, a software module, or a hardware structure plus a software module. As shown in FIG. 8, the device 700 includes a processing module 701 and a sending module 702.
  • the processing module 701 is used to determine the information of the API and the shared information of the API, and the shared information is used to instruct the first CCF entity to share the API.
  • the sending module 702 is configured to send a first API publishing request to the first CCF entity, where the first API publishing request includes API information and API sharing information.
  • the sharing information includes at least one of sharing indication information, target CCF entity information, or target domain indication information; where the sharing indication information is used to indicate sharing of APIs to be shared; the target domain indication information is used to indicate the target domain , The target domain is different from the domain to which the first CCF entity belongs.
  • the sharing information includes sharing range indication information; the sharing range indication information is used to indicate the sharing range of the API to be shared.
  • the shared information further includes target domain indication information, and the target domain indication information is used to indicate the target domain to which the target CCF entity belongs.
  • the target domain indication information is the identification of the target domain; or, the target domain indication information includes the identification of the target domain and the out-of-domain target CCF entity information, wherein the out-of-domain target CCF entity information is used to indicate that the API to be shared is in the target Information about the target CCF entity in the domain.
  • the processing module 701 can be used to perform at least S401 in FIG. 4 or S601 in FIG. 5A , And / or perform other steps described in this application.
  • the sending module 702 can at least be used to execute S402 in FIG. 4 or S602 in FIG. 5A, and / or perform other steps described in this application, which will not be repeated here.
  • the device 600 or the device 700 may be presented in the form of dividing each functional module in an integrated manner.
  • the "module” herein may refer to a specific ASIC, circuit, processor and storage device that executes one or more software or firmware programs, integrated logic circuits, and / or other devices that can provide the above functions.
  • the device 600 or the device 700 may take the form shown in FIG. 2.
  • the processing module 601 in FIG. 6 or FIG. 7, or the processing module 701 in FIG. 8 may be implemented by the processor 201 or the processor 208; the sending module 602 in FIG. 6 or FIG. 7, or The receiving module 603 in FIG. 7 or the sending module 702 in FIG. 8 may be implemented through the communication interface 204.
  • a person of ordinary skill in the art may know that all or part of the steps in the above method may be completed by hardware related to a program instruction, and the program may be stored in a computer-readable storage medium, such as ROM, RAM, and optical disk, etc. .
  • An embodiment of the present application further provides a storage medium, and the storage medium may include a memory 203.
  • the computer program product includes one or more computer instructions.
  • the computer may be a general-purpose computer, a dedicated computer, a computer network, network equipment, user equipment, or other programmable devices.
  • the computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be from a website site, computer, server or data center Transmission to another website, computer, server or data center via wired (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, microwave, etc.).
  • the computer-readable storage medium may be any available medium that can be accessed by a computer or a data storage device including one or more servers and data centers that can be integrated with the medium.
  • the usable medium may be a magnetic medium (for example, a floppy disk, a hard disk, a magnetic tape), an optical medium (for example, digital video disc (digital video disc, DVD)), or a semiconductor medium (for example, solid state disk (SSD)) Wait.
  • a magnetic medium for example, a floppy disk, a hard disk, a magnetic tape
  • an optical medium for example, digital video disc (digital video disc, DVD)
  • a semiconductor medium for example, solid state disk (SSD)

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer And Data Communications (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本申请实施例公开了一种API发布方法及装置,涉及通信技术领域。可以实现将API发布到多个CCF实体。该方法可以包括:第一CCF实体确定待共享API;第一CCF实体向待共享API的目标CCF实体共享待共享API的信息。

Description

一种API发布方法及装置
本申请要求于2018年11月05日提交国家知识产权局、申请号为201811309187.8、申请名称为“一种API发布方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请要求于2019年01月14日提交国家知识产权局、申请号为201910033213.7、申请名称为“一种API发布方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信技术领域,尤其涉及一种API发布方法及装置。
背景技术
为了更好地支持业务,运营商可以以应用程序接口(application program interface,API)的形式对应用提供网络服务或网络能力。第三代合作伙伴计划(third generation partnership project,3GPP)定义了一套通用API框架(common API framework,CAPIF),主要用于API的发布、发现及管理。在该架构下,应用可以方便快捷地使用API。
CAPIF系统架构支持一个或者多个通用应用程序接口核心(CAPIF core function,CCF)实体,并定义了多个CCF实体的接口。一个CCF实体通常支持一个区域内的API的发布、认证等功能。目前,API发布时,仅会发布到一个CCF实体。
随着新的部署场景和商业模式发展,比如车联网(vehicle to everything,V2X)业务,一方面同一个V2X应用的用户可能来自不同的公共陆地移动网(public land mobile network,PLMN),另一方面,同一个V2X应用的业务覆盖范围可能跨PLMN,而即使在同一个PLMN内,一个本地应用也可以跨越多个区域;对于不同的PLMN之间的互联互通,以及同一个PLMN内多个区域的互联互通的需求越来越大。如何将API发布到多个CCF实体是需要解决的一个问题。
发明内容
本申请实施例提供的API发布方法,可以实现将API发布到多个CCF实体。
为达到上述目的,本申请的实施例采用如下技术方案:
第一方面,本申请提供了一种API发布方法及通信装置。
在一种可能的设计中,该API发布方法可以包括:第一CCF实体确定待共享API;第一CCF实体向待共享API的目标CCF实体共享该待共享API的信息。在该方法中,第一CCF实体可以将API共享到其他的CCF实体,实现将API发布到多个CCF实体。这样,一个API可以通过多个CCF实体各自对应的AEF实体提供调用,使得API调用实体可以通过多个CCF实体发现并获取到API。
结合第一方面,在一种可能的设计中,第一CCF实体接收第一API发布请求,第一API发布请求包括API的信息和API的共享信息;第一CCF实体根据第一API发布请求,确定待共享API;并且,第一CCF实体根据共享信息,确定目标CCF实体。 在该方法中,由发布实体确定共享API和共享API的目标CCF实体。
在一种可能的设计中,共享信息包括共享指示信息、目标CCF实体的信息或目标域指示信息中至少一个;其中,共享指示信息用于指示共享待共享API;目标域指示信息用于指示目标域,该目标域与第一CCF实体所属域不同。
在一种可能的设计中,共享信息包括共享指示信息,第一CCF实体根据第一预设规则确定目标CCF实体;或者,共享信息包括目标CCF实体的信息,第一CCF实体根据目标CCF实体的信息确定目标CCF实体;或者,共享信息包括目标域指示信息,第一CCF实体根据目标域指示信息确定第二目标CCF实体,其中,第二目标CCF实体为目标CCF实体中一个或多个,第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种可能的设计中,目标域指示信息为目标域的标识,第一CCF实体根据第二预设规则,在目标域内确定第二目标CCF实体;或者,目标域指示信息包括目标域的标识和域外目标CCF实体信息,第一CCF实体根据域外目标CCF实体信息,在目标域内确定第二目标CCF实体。
在另一种可能的设计中,共享信息包括共享范围指示信息,共享范围指示信息用于指示待共享API的共享范围。在该方法中,API实体确定共享API的范围。
在一种可能的设计中,待共享API的共享范围为第一CCF实体所属域内的CCF实体,第一CCF实体在第一CCF实体所属域内的CCF实体中确定目标CCF实体。
在另一种可能的设计中,待共享API的共享范围为第一CCF实体所属域外的CCF实体,第一CCF实体在第一CCF实体所属域外的CCF实体中确定目标CCF实体。
在另一种可能的设计中,待共享API的共享范围包括第一CCF实体所属域内的CCF实体,和第一CCF实体所属域外的CCF实体,第一CCF实体在第一CCF实体所属域内的CCF实体中确定第一目标CCF实体,并且在第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,其中,目标CCF实体包括第一目标CCF实体和第二目标CCF实体。
其中,第一目标CCF实体为目标CCF实体中一个或多个,第一目标CCF实体所属域与第一CCF实体所属域相同;第二目标CCF实体为目标CCF实体中一个或多个,第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种可能的设计中,共享信息还包括目标域指示信息;其中,目标域指示信息用于指示目标CCF实体所属的目标域。第一CCF实体在第一CCF实体所属域外的CCF实体中确定目标CCF实体,包括:第一CCF实体在目标域内的CCF实体中确定目标CCF实体。第一CCF实体在第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,包括:第一CCF实体在目标域内的CCF实体中确定第二目标CCF实体。
结合第一方面,在一种可能的设计中,第一CCF实体根据第三预设规则,确定待共享API。进一步,根据第四预设规则,确定目标CCF实体。在该实现方式中,由CCF实体确定共享API和共享API的目标CCF实体。
在一种可能的实现中,目标CCF实体包括第一目标CCF实体,和/或第二目标CCF实体;其中,第一目标CCF实体所属域与第一CCF实体所属域相同;第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种可能的实现中,第一CCF实体向第二目标CCF实体共享待共享API的信息,其中,待共享API的信息为全局信息。在该实现方式中,由于第二目标CCF实体所属域与第一CCF实体所属域不同,采用全局信息以便于第二目标CCF实体可以识别。
在一种可能的实现中,待共享API的信息包括待共享API的接口信息,其中,接口信息为拓扑隐藏入口点的信息。在该实现方式中,不同的域之间的接口信息进行拓扑隐藏,不展示网络内部拓扑,可以使不同域的实体之间交互更便捷,且保证系统安全性。
相应的,本申请还提供了一种通信装置,该装置可以实现第一方面所述的API发布方法。例如,该装置可以是CCF实体或应用于CCF实体的芯片,还可以是其他能够实现上述API发布方法的装置,其可以通过软件、硬件、或者通过硬件执行相应的软件实现上述方法。
在一种可能的设计中,该装置可以包括处理器和存储器。该处理器被配置为支持该装置执行上述第一方面方法中相应的功能。存储器用于与处理器耦合,其保存该装置必要的程序指令和数据。另外该装置中还可以包括通信接口,用于支持该装置与其他装置之间的通信。该通信接口可以是收发器或收发电路。
在一种可能的设计中,该装置可以包括:处理模块和发送模块。其中,处理模块,用于确定待共享API;发送模块,用于向待共享API的目标CCF实体共享待共享API的信息。
在一种可能的设计中,该装置还包括:接收模块。接收模块,用于接收第一API发布请求,其中包括API的信息和API的共享信息;处理模块,具体用于根据第一API发布请求,确定待共享API。
在一种可能的设计中,处理模块,还用于根据共享信息,确定目标CCF实体。
在一种可能的设计中,共享信息包括共享指示信息、目标CCF实体的信息或目标域指示信息中至少一个;其中,共享指示信息用于指示共享待共享API;目标域指示信息用于指示目标域,该目标域与第一CCF实体所属域不同。
在一种可能的设计中,共享信息包括共享指示信息,处理模块用于根据第一预设规则确定所述目标CCF实体;或者,共享信息包括目标CCF实体的信息,处理模块用于根据目标CCF实体的信息确定目标CCF实体;或者,共享信息包括目标域指示信息,处理模块用于根据目标域指示信息确定第二目标CCF实体,其中,第二目标CCF实体为目标CCF实体中一个或多个,第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种可能的设计中,共享信息包括共享范围指示信息;共享范围指示信息用于指示待共享API的共享范围。
在一种可能的设计中,待共享API的共享范围为第一CCF实体所属域内的CCF实体,处理模块,用于在第一CCF实体所属域内的CCF实体中确定目标CCF实体。
在另一种可能的设计中,待共享API的共享范围为第一CCF实体所属域外的CCF实体,处理模块,用于在第一CCF实体所属域外的CCF实体中确定目标CCF实体。
在另一种可能的设计中,待共享API的共享范围包括第一CCF实体所属域内的 CCF实体,和第一CCF实体所属域外的CCF实体,处理模块,用于在第一CCF实体所属域内的CCF实体中确定第一目标CCF实体,并且在第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,其中,目标CCF实体包括第一目标CCF实体和第二目标CCF实体。
其中,第一目标CCF实体为目标CCF实体中一个或多个,第一目标CCF实体所属域与第一CCF实体所属域相同;第二目标CCF实体为目标CCF实体中一个或多个,第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种可能的设计中,共享信息还包括目标域指示信息;其中,目标域指示信息用于指示目标CCF实体所属的目标域。
在一种可能的设计中,处理模块在第一CCF实体所属域外的CCF实体中确定目标CCF实体,具体包括:处理模块在目标域内的CCF实体中确定目标CCF实体。在一种可能的设计中,处理模块在第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,具体包括:处理模块在目标域内的CCF实体中确定第二目标CCF实体。
在一种可能的设计中,目标域指示信息为目标域的标识,处理模块具体用于根据第二预设规则,在目标域内确定第二目标CCF实体;或者,目标域指示信息包括目标域的标识和域外目标CCF实体信息,处理模块具体用于根据域外目标CCF实体信息,在目标域内确定第二目标CCF实体。
在一种可能的设计中,处理模块具体用于:根据第三预设规则,确定待共享API。
在一种可能的设计中,处理模块具体用于:根据第四预设规则,确定目标CCF实体。
在一种可能的设计中,目标CCF实体包括第一目标CCF实体,和/或第二目标CCF实体;其中,第一目标CCF实体所属域与第一CCF实体所属域相同;第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种可能的设计中,发送模块向待共享API的目标CCF实体共享待共享API的信息,具体包括:发送模块向第二目标CCF实体共享待共享API的信息,其中,待共享API的信息为全局信息。
在一种可能的设计中,该待共享API的信息包括待共享API的接口信息,其中,该接口信息为拓扑隐藏入口点的信息。
第二方面,本申请提供了一种API发布方法及装置。
在一种可能的设计中,该方法可以包括:API发布实体确定API的信息以及API的共享信息,其中,共享信息用于指示第一CCF实体共享API;该API发布实体向第一CCF实体发送第一API发布请求,其中,第一API发布请求包括API的信息和API的共享信息。在该方法中,API发布实体可以在向第一CCF实体发送的API发布请求消息中指示是否共享API,第一CCF实体可以根据共享信息向其他CCF实体共享待共享API的信息,实现将API发布到多个CCF实体。这样,API调用实体可以通过多个CCF实体发现并获取到API。
在一种可能的设计中,共享信息包括共享指示信息、目标CCF实体的信息或目标域指示信息中至少一个;其中,共享指示信息用于指示共享待共享API;目标域指示信息用于指示目标域,该目标域与第一CCF实体所属域不同。
在一种可能的设计中,共享信息包括共享范围指示信息;共享范围指示信息用于指示待共享API的共享范围。
在一种可能的设计中,共享信息还包括目标域指示信息,目标域指示信息用于指示目标CCF实体所属的目标域。
在一种可能的设计中,目标域指示信息为目标域的标识;或者,目标域指示信息包括目标域的标识和域外目标CCF实体信息,其中,域外目标CCF实体信息用于指示待共享API在目标域内的目标CCF实体信息。
相应的,本申请还提供了一种通信装置,该装置可以实现第二方面所述的API发布方法。例如,该装置可以是API发布实体或应用于API发布实体的芯片,还可以是其他能够实现上述API发布方法的装置,其可以通过软件、硬件、或者通过硬件执行相应的软件实现上述方法。
在一种可能的设计中,该装置可以包括处理器和存储器。该处理器被配置为支持该装置执行上述第二方面方法中相应的功能。存储器用于与处理器耦合,其保存该装置必要的程序指令和数据。另外该装置中还可以包括通信接口,用于支持该装置与其他装置之间的通信。该通信接口可以是收发器或收发电路。
在一种可能的设计中,该装置可以包括:处理模块和发送模块。其中,处理模块,用于确定API的信息以及API的共享信息,共享信息用于指示第一CCF实体共享API;发送模块,用于向第一CCF实体发送第一API发布请求,其中,第一API发布请求包括API的信息和API的共享信息。
在一种可能的设计中,共享信息包括共享指示信息、目标CCF实体的信息或目标域指示信息中至少一个;其中,共享指示信息用于指示共享待共享API;目标域指示信息用于指示目标域,该目标域与第一CCF实体所属域不同。
在一种可能的设计中,共享信息包括共享范围指示信息;共享范围指示信息用于指示待共享API的共享范围。
在一种可能的设计中,共享信息还包括目标域指示信息,目标域指示信息用于指示目标CCF实体所属的目标域。
在一种可能的设计中,目标域指示信息为目标域的标识;或者,目标域指示信息包括目标域的标识和域外目标CCF实体信息,其中,域外目标CCF实体信息用于指示待共享API在目标域内的目标CCF实体信息。
本申请还提供了一种计算机可读存储介质,该计算机可读存储介质中存储有指令,当其在计算机上运行时,使得计算机执行上述任一方面所述的方法。
本申请还提供了一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行上述任一方面所述的方法。
本申请还提供了一种芯片系统,该芯片系统中包括处理器,还可以包括存储器,用于实现上述任一方面所述的方法。
本申请提供了一种通信系统,包括上述用于实现第一方面所述的方法的装置,以及上述用于实现第二方面所述的方法的装置。
上述提供的任一种装置或计算机存储介质或计算机程序产品或芯片系统或通信系统均用于执行上文所提供的对应的方法,因此,其所能达到的有益效果可参考上文提 供的对应的方法中对应方案的有益效果,此处不再赘述。
附图说明
图1为本申请实施例提供的技术方案所适用的一种系统架构的示意图;
图2为本申请实施例提供的技术方案所适用的一种通信装置的结构示意图;
图3为本申请实施例提供的一种API发布方法的示意图一;
图4为本申请实施例提供的一种API发布方法的示意图二;
图5为本申请实施例提供的一种API发布方法的示意图三;
图5A为本申请实施例提供的一种API发布方法的示意图四;
图6为本申请实施例提供的一种通信装置的结构示意图一;
图7为本申请实施例提供的一种通信装置的结构示意图二;
图8为本申请实施例提供的一种通信装置的结构示意图三。
具体实施方式
下面结合附图对本申请实施例提供的API发布方法及装置进行详细描述。
本申请提供的技术方案可以应用于图1所示的CAPIF系统架构。该系统架构中可以包括API调用(API invoker)实体、CCF实体、API开放(API exposing function,AEF)实体、API发布(API publishing function,APF)实体和API管理(API management function,APIMF)实体等。
API调用实体是调用、访问、使用API的逻辑功能实体,也可以称为API调用者。其支持的能力可以包括:API调用实体的认证,比如,通过认证API调用实体的标识及其他信息实现认证;与CAPIF的相互鉴权;访问API之前获取授权;发现APIs;调用API等。API调用实体(API调用者)可以为与PLMN运营商签定了服务协议的第三方应用,也可以是PLMN运营商自己的应用。比如,机器对机器(machine to machine,M2M)应用、物联网(internet of vehicles,IoT)应用、V2X应用等。
CCF实体用于提供CAPIF的API。其支持的能力可以包括:基于API调用实体的标识和其他信息认证API调用实体;与API调用实体的相互鉴权;在API调用实体访问API之前向API调用实体提供授权;发布,存储和支持API的发现;基于PLMN运营商的策略负责API的访问控制;存储API调用的日志,并提供给授权实体;基于API的日志进行计费;检测API的调用;API调用实体的注册;存储配置策略;对调用日志的审计等。
AEF实体用于提供API,同时也是API调用实体调用API的入口。其支持的能力可以包括:基于API调用实体的标识和CCF实体提供的其他信息认证API调用实体;确认CCF提供的授权;将API日志同步到CCF实体上等。
APF实体提供API发布的功能,以便API调用实体可以发现API。其支持的能力可以包括:发布API功能。
APIMF实体提供对API的管理功能。其支持的能力可以包括:审计从CCF实体提供的API调用日志;监控CCF实体报告的事件;向API配置API提供者的策略;检测API的状态;注册API调用实体。
其中,AEF实体、APF实体和APIMF实体属于API提供域,一个API提供域(API provider domain)可以包含一个APF实体,一个APIMF实体,一个或多个AEF实体。
该系统架构中可以包括一个或者多个信任域,比如一个信任域可以是一个PLMN网络 域,示例性的,信任域A是运营商A的PLMN网络域,信任域B是运营商B的PLMN网络域;一个信任域的实体由同一个运营商控制并提供足够的安全保护,根据安全控制的粒度不同,同一个运营商内部也可以划分为不同的信任域。比如,一个信任域可以是一个PLMN网络域中的一个地区对应的网络,示例性的,信任域A是运营商Z在西北地区的PLMN网络,信任域B是运营商Z在北京地区的PLMN网络。在本申请中,一个信任域称为一个域。一个域可以包括API调用实体、AEF实体、APF实体、APIMF实体以及一个或多个CCF实体。比如,API开放实体1、API发布实体1、API管理实体1、CCF实体1、API开放实体2、API发布实体2、API管理实体2、CCF实体2以及API调用实体1属于信任域A;API开放实体3、API发布实体3、API管理实体3、CCF实体3以及API调用实体2属于信任域B。
其中,一个信任域内的AEF实体可以通过CAPIF-3接口与CCF实体通信,APF实体可以通过CAPIF-4接口与CCF实体通信,APIMF实体可以通过CAPIF-5接口与CCF实体通信,不同的CCF实体之间可以通过CAPIF-6接口通信;一个信任域内的API调用实体可以通过CAPIF-2接口调用该信任域内的API。不属于一个信任域(即信任域外)的API调用实体可以通过CAPIF-2e接口调用属于该信任域内的API。比如,API调用实体1与运营商A有签约关系,运营商A的PLMN网络域为信任域A,即API调用实体1属于信任域A,即API调用实体1在信任域A内。
每个信任域可以有一个最顶级的(域边界的)CCF实体,还可以有0个或多个低级的CCF实体与之相连;并且,一个信任域的最顶级的CCF实体还可以与其他信任域的最顶级的CCF实体有连接,不同信任域的CCF实体之间通过CAPIF-6e通信。其中,CAPIF-6(同一个信任域的CAPIF内的两个CCF之间的接口)至少支持CAPIF3、CAPIF4以及CAPIF5接口功能;CAPIF-6e可以支持跨系统安全性的CAPIF3,CAPIF4以及CAPIF5接口功能。
可选的,图1中的各个功能实体可以由一个实体设备实现,也可以由多个实体设备共同实现,还可以是一个实体设备内的一个逻辑功能模块,本申请实施例对此不作具体限定。
示例性的,上述网络架构中,API调用实体、AEF实体、APF实体、APIMF实体或CCF实体可以是PLMN网络中的设备;比如,可以是4G或5G移动通信系统中的设备。API调用实体、AEF实体、APF实体、APIMF实体或CCF实体可以运行在终端设备中,也可以运行在网络设备中。示例性的,API调用实体可以是4G通信系统中的移动管理(mobility management entity,MME)实体、无线接入网(radio access network,RAN)设备、策略与计费规则功能(policy and charging rules function,PCRF)实体、归属签约用户服务器(home subscriber server,HSS)、广播组播服务中心(broadcast-multicast service centre,BM-SC)、服务呼叫会话控制实体(service-call session control function,S-CSCF)或应用(application function,AF)实体等;API调用实体也可以是5G通信系统中的接入与移动管理功能(access and mobility management function,AMF)实体、会话管理功能(session management function,SMF)实体、统一数据管理(unified data management,UDM)实体、用户面功能(user plane function,UPF)实体、策略控制功能(policy control function,PCF)实体、鉴权服务器功能(authentication server function,AUSF)实体、网络开放(network exposure function,NEF)实体、网络切片选择(network slice selection function,NSSF)实体、网络功能仓库(network function repository function,NRF)实体或AF实体等。
AEF实体可以运行在4G网络中的业务能力开放(service capability exposure function,SCEF)实体。AEF实体也可以运行在5G网络中的NEF,或者是AMF实体、SMF实体、UDM实体、PCF实体、NRF实体、AUSF实体、NSSF实体。
CCF实体可以独立实现部署在一个独立的网络实体;或者CCF实体也可以和API提供域内的实体一起部署在4G网络的SCEF或5G网络的NEF。
需要说明的是,本申请实施例描述的系统架构是为了更加清楚的说明本申请实施例的技术方案,并不构成对于本申请实施例提供的技术方案的限定,本领域普通技术人员可知,随着系统架构的演变,本申请实施例提供的技术方案对于类似的技术问题,同样适用。
在一种示例中,如图2所示,图1中的API调用实体、AEF实体、APF实体、APIMF实体以及CCF实体均可以通过图2中的装置200来实现。
图2所示为本申请实施例提供的装置200的硬件结构示意图。装置200包括至少一个处理器201,通信总线202,存储器203以及至少一个通信接口204。
处理器201可以是一个通用中央处理器(central processing unit,CPU),微处理器,特定应用集成电路(application-specific integrated circuit,ASIC),或一个或多个用于控制本申请方案程序执行的集成电路。
通信总线202可包括一通路,在上述组件之间传送信息。
通信接口204,使用任何收发器一类的装置,用于与其他设备或通信网络通信,如以太网,无线接入网(radio access network,RAN),无线局域网(wireless local area networks,WLAN)等。
存储器203可以是只读存储器(read-only memory,ROM)或可存储静态信息和指令的其他类型的静态存储设备,随机存取存储器(random access memory,RAM)或者可存储信息和指令的其他类型的动态存储设备,也可以是电可擦可编程只读存储器(electrically erasable programmable read-only memory,EEPROM)、只读光盘(compact disc read-only memory,CD-ROM)或其他光盘存储、光碟存储(包括压缩光碟、激光碟、光碟、数字通用光碟、蓝光光碟等)、磁盘存储介质或者其他磁存储设备、或者能够用于携带或存储具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其他介质,但不限于此。存储器可以是独立存在,通过总线与处理器相连接。存储器也可以和处理器集成在一起。
其中,存储器203用于存储执行本申请方案的应用程序代码,并由处理器201来控制执行。处理器201用于执行存储器203中存储的应用程序代码,从而实现本申请下述实施例提供的API发布方法。
在具体实现中,作为一种实施例,处理器201可以包括一个或多个CPU,例如图2中的CPU0和CPU1。
在具体实现中,作为一种实施例,装置200可以包括多个处理器,例如图2中的处理器201和处理器208。这些处理器中的每一个可以是一个单核(single-CPU)处理器,也可以是一个多核(multi-CPU)处理器。这里的处理器可以指一个或多个设备、电路、和/或用于处理数据(例如计算机程序指令)的处理核。
在具体实现中,作为一种实施例,装置200还可以包括输出设备205和输入设备206。输出设备205和处理器201通信,可以以多种方式来显示信息。例如,输出设备205可以 是液晶显示器(liquid crystal display,LCD),发光二级管(light emitting diode,LED)显示设备,阴极射线管(cathode ray tube,CRT)显示设备,或投影仪(projector)等。输入设备206和处理器201通信,可以以多种方式接受用户的输入。例如,输入设备206可以是鼠标、键盘、触摸屏设备或传感设备等。
上述的装置200可以是一个通用通信设备或者是一个专用通信设备。在具体实现中,装置200可以是台式机、便携式电脑、网络服务器、掌上电脑(personal digital assistant,PDA)、移动手机、平板电脑、无线终端设备、嵌入式设备或有图2中类似结构的设备。本申请实施例不限定装置200的类型。
为了方便理解本申请实施例的技术方案,下面对本申请涉及到的术语进行解释。
1、共享API
API发布实体将API发布至一个CCF实体后,CCF实体可以将这些API发布至该CCF实体所属域内的其他CCF实体,或者将这些API发布至该CCF实体所述域外的其他CCF实体。一个CCF实体将获取到的API发布至其他CCF实体的过程称为共享API。
2、目标CCF实体
API从一个CCF实体共享至其他的一个或者多个CCF实体过程中,执行该共享过程的CCF实体为源CCF实体,接收该共享的API的一个或者多个CCF实体即为共享API的目标CCF实体。
3、目标域
CAPIF系统架构下可以包括多个域,每个域可以包括一个或者多个CCF实体。在共享API的过程中,如果目标CCF实体所属域与源CCF实体所属域不同,该目标CCF实体所属域即为源CCF实体共享API的目标域。比如,CCF实体1属于信任域A,CCF实体3属于信任域B,如果CCF实体1将API共享至CCF实体3,则信任域B为CCF实体1共享API的目标域。
在本申请的描述中,除非另有说明,“/”表示或的意思,例如,A/B可以表示A或B;本文中的“和/或”仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。并且,在本申请的描述中,除非另有说明,“多个”是指两个或多于两个。另外,为了便于清楚描述本申请实施例的技术方案,在本申请的实施例中,采用了“第一”、“第二”等字样对功能和作用基本相同的相同项或相似项进行区分。本领域技术人员可以理解“第一”、“第二”等字样并不对数量和执行次序进行限定,并且“第一”、“第二”等字样也并不限定一定不同,本申请实施例对此不作具体限定。在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。
下面将结合图1和图2对本申请实施例提供的API发布方法进行具体阐述。
实施例一:
本申请实施例提供一种API发布方法。如图3所示,该方法可以包括如下步骤:
S301、第一CCF实体确定待共享API。
API提供者可以通过API发布实体将AEF实体上的API发布至CCF实体。这样,API 调用实体可以通过CCF实体发现并获取到AEF实体提供的API,进而调用该API。调用API也可以理解为访问API,通过调用API,API调用实体可以获取需要的资源及服务,比如广播传输资源,视频加速服务等。
第一CCF实体可以是CAPIF系统架构中的一个CCF实体,API提供者的API发布实体与该第一CCF实体通过CAPIF-4接口相连,比如,第一CCF实体是一个域的域边界的CCF实体。示例性的,第一CCF实体是图1中的CCF实体1。
对于发布至第一CCF实体的API,第一CCF实体可以将其共享至目标CCF实体,这样,API调用实体可以通过目标CCF实体发现并获取到被共享的API。
第一CCF实体确定待共享API。在一种实现方式中,如实施例二或实施例四,第一CCF实体从API发布实体接收第一API发布请求消息,并根据第一API发布请求消息确定待共享API。在另一种实现方式中,如实施例三,第一CCF实体根据第三预设规则确定待共享API。
S302、第一CCF实体向待共享API的目标CCF实体共享待共享API的信息。
第一CCF实体确定待共享API的目标CCF实体。在一种实现方式中,第一CCF实体从API发布实体接收第一API发布请求消息,并根据第一API发布请求消息确定待共享API的目标CCF实体。在另一种实现方式中,第一CCF实体根据第四预设规则,确定待共享API的目标CCF实体。
进一步的,第一CCF实体向待共享API的目标CCF实体共享待共享API的信息。
其中,API的信息可以包括API的标识、API的类型或API的接口信息等。比如,API的标识用于标识API,示例性的,API的标识可以为API的编号(如:字母、数字或特殊符号等,或字母、数字、特殊符号等其中至少两项的自由组合),还可以为API的名称、API的索引或API的统一资源标识符(uniform resource locator,URL)等;API的类型可以是V2X业务、IoT业务或者M2M业务等;API的接口信息可以是AEF实体的全限定域名(fully qualified domain name,FQDN),AEF实体的网际协议(internet protocol,IP)地址,或AEF实体的端口号,或AEF实体的IP地址和端口号等。
示例性的,API的信息如表1所示:
表1
API的标识 API的类型 API的接口信息
1 V2X业务 192.0.0.0
2 IoT业务 192.0.0.1
需要说明的是,如果目标CCF实体所属域与第一CCF实体所属域相同,API的信息可以是域内唯一的信息,比如,API的标识是域内唯一的标识;如果目标CCF实体所属域与第一CCF实体所属域不同,API的信息可以是全局信息,比如,API的标识是全局唯一的标识。其中,全局信息可以理解为CAPIF系统中所有域都可识别的API的信息。全局地址可以理解为CAPIF系统中所有域都可识别的地址。
本申请实施例提供的API发布方法,第一CCF实体可以将API共享到其他的CCF实体,实现将API发布到多个CCF实体。这样,API调用实体可以通过多个CCF实体发现并获取到该API。
实施例二:
本申请实施例提供一种API发布方法。如图4所示,该方法可以包括如下步骤:
S401、API发布实体确定API的信息以及API的共享信息。
API发布实体确定API的信息,该API为待共享API,并确定该API的共享信息。
其中,API发布实体可以是APF实体,或者,API发布实体也可以是APIMF实体,当然API发布实体还可以是CAPIF系统架构中的其他实体,本申请实施例对此不进行限定。本申请实施例中以API发布实体为APF实体为例进行说明。
在一种实现方式中,API发布实体接收用户的指令(比如用户通过人机交互操作页面选择待发布的API以及待发布API的目标CCF实体),获取待共享API以及待共享API的目标CCF实体。
在另一种实现方式中,API发布实体可以根据第五预设规则确定待共享的API以及待共享API的目标CCF实体。示例性的,第五预设规则可以是商业签约信息与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的域的映射关系),或API的类型,或API的类型与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的逻辑域或者地理区域的映射关系)等。比如,运营商B与运营商A有API共享使用的签约,即对于运营商A的任何一个API,运营商B都可以获取并使用该API。运营商A的API发布实体根据与运营商B的API共享使用的签约信息确定将该API发布至运营商B对应的信任域(示例性的,图1中CCF实体3)。再比如,第五预设规则可以是将V2X类型的API共享至CCF3,将IoT类型的API共享至CCF2,则当API1为V2X类型的API,APF实体1确定将API1共享至CCF实体3;当API2为IoT类型的API,APF实体1确定将API2共享至CCF实体2。当然,API发布1实体还可以根据其他规则确定共享API的目标CCF实体,本申请实施例对此不进行限定。
在一种实现方式中,API发布实体将API发布至与该API发布实体通过CAPIF-4接口连接的CCF实体(简称该API发布实体对应的CCF实体);此时,API发布实体不决定是否共享该API,而是由API发布实体对应的CCF实体决定是否共享该API,示例性的,API发布实体向对应的CCF实体发送第三API发布请求消息,其中,第三API发布请求消息包括API的信息。示例性的,第三API发布请求消息可以是服务API发布请求(service API publish request),或者服务API配置请求(service API configuration request)。示例性的,API发布实体向与该API发布实体对应的CCF实体发送该API的信息。比如,图1中API发布实体1向CCF实体1发送API1、API2和API3的信息。此时API发布实体可以不生成API的共享信息,也不向CCF实体发送API的共享信息。
在另一种实现方式中,API发布实体确定是否共享该API。如果API发布实体确定禁止共享该API,在一种示例中,API发布实体将该API的信息和禁止共享API的指示信息发送至第一CCF实体;在另一种示例中,API发布实体仅将该API的信息发送至第一CCF实体,则表示禁止共享该API。如果API发布实体确定共享该API,则确定该待共享API的共享信息,其中,API的共享信息用于指示第一CCF实体共享待共享的API,共享信息可以包括共享指示信息、域内目标CCF实体信息或目标域指示信息中至少一个。其中,共享指示信息用于指示共享待共享API;目标域指示信息用于指示目标域,该目标域与第一CCF实体所属域不同;域内目标CCF实体信息用于指示待共享API在第一CCF实体所属域内的目标CCF实体信息。示例性的,在一种实现方式中,禁止共享API 的指示信息与共享指示信息可以使用一个参数的不同值来表示;比如参数值为0,表示禁止共享;参数值为1,表示共享;参数值为2,表示不指定是否共享;或者,禁止共享API的指示信息与共享指示信息也可以使用不同的参数来实现。
其中,域内目标CCF实体信息可以为,CCF实体的标识、FQDN域名、IP地址或者IP地址和端口号,或者为URL等。目标域指示信息可以是目标域的标识,比如PLMN ID,域名(如domain.com);或者,目标域指示信息还可以包括目标域的标识和域外目标CCF实体信息,其中,域外目标CCF实体信息可以为CCF实体的标识,可以是FQDN域名,IP地址,或者IP地址和端口号,或者为URL等。
在一些实施例中,共享信息还可以包括目标CCF实体的信息。其中,目标CCF实体的信息可以为,CCF实体的标识、FQDN域名、IP地址或者IP地址和端口号,或者为URL等。
需要说明的是,共享指示信息、域内目标CCF实体信息或目标域指示信息可以以多种方式组合出现,本申请实施例对此不做限定。比如,共享信息为共享指示信息;共享信息为域内目标CCF实体信息;共享信息为目标域指示信息;共享信息包括共享指示信息和域内目标CCF实体信息;共享信息包括共享指示信息和目标域指示信息;共享信息包括域内目标CCF实体信息和目标域指示信息;或者,共享信息包括共享指示信息、域内目标CCF实体信息和目标域指示信息。目标CCF实体的信息可以单独出现,也可以与共享指示信息、域内目标CCF实体信息或目标域指示信息组合出现,本申请实施例对此不做限定。
示例性的,图1中信任域A为运营商A的PLMN网络域,CCF实体1为运营商A部署在西安地区的CCF实体,用于管理西安地区的AEF实体提供的API,CCF实体2是运营商A部署宁夏地区的的CCF实体,用于管理宁夏地区的AEF实体提供的API,API发布实体1为西安地区的运营商A,API发布实体2为宁夏地区的运营商A;信任域B为运营商B的PLMN网络域。API发布实体(API发布实体1)确定将API1发布至CCF实体1;确定将API2共享至宁夏地区,则确定将API2发布至CCF实体1,并由CCF实体1发布至CCF实体2;确定将API3共享至宁夏地区以及运营商B的PLMN网络域,则确定将API3发布至CCF实体1,并由CCF实体1发布至CCF实体2和CCF实体3;继而,API发布实体1可以确定不指定共享API1,指定待共享API包括API2和API3。
在一种实现方式中,API发布实体(API发布实体1)确定共享信息为共享指示信息,该共享指示信息指示第一CCF实体(CCF实体1)共享待共享API(API2和API3),此时由CCF实体确定共享API的目标CCF。
在另一种实现方式中,API发布实体(API发布实体1)确定共享API2的目标CCF实体为CCF实体2,并确定共享信息包括域内目标CCF实体信息,其中域内目标CCF实体信息包括CCF实体2的信息。在一些示例中,API发布实体(API发布实体1)确定共享API2的目标CCF实体为CCF实体2,并确定共享信息包括目标CCF实体的信息,即包括CCF实体2的信息。
在又一种实现方式中,API发布实体(API发布实体1)确定共享API3的目标CCF实体包括CCF实体2和CCF实体3;并确定共享信息包括域内目标CCF实体信息和目标域指示信息,其中,域内目标CCF实体信息包括CCF实体2的信息,目标域指示信息指 示信任域B(CCF实体3所属域)。在一些示例中,API发布实体(API发布实体1)确定共享API3的目标CCF实体包括CCF实体2和CCF实体3,并确定共享信息包括目标CCF实体(CCF实体2和CCF实体3)的信息。
在另一示例中,图1中信任域A为运营商A的PLMN网络域,CCF实体1为运营商A部署的顶级的(也可称为域边界的)CCF实体,用于管理运营商A整个网络域的API及其他CCF实体,CCF实体2是运营商A部署在宁夏地区的CCF实体,用于管理宁夏地区的AEF实体提供的API;信任域B为运营商B的PLMN网络域,CCF实体3为运营商B的PLMN的网络域的顶级的(也可称为域边界的)CCF实体,用于管理运营商B整个网络域的API及其域内的其他CCF实体。宁夏地区的API发布实体2确定API2需要共享到运营商A的全网,则将API2发布至CCF实体2,并由CCF实体2将API2发布至CCF实体1;宁夏地区的API发布实体2确定API3需要共享到运营商A的PLMN网络域和运营商B的PLMN网络域,则将API3发布至CCF实体2,并由CCF实体2将API3发布至CCF实体1和CCF实体3;继而,API发布实体2可以确定待共享API为API2和API3。
在一种实现方式中,API发布实体(API发布实体2)确定共享信息为共享指示信息,该共享指示信息指示第一CCF实体(CCF实体2)共享待共享API(API2和API3)。
在另一种实现方式中,API发布实体(API发布实体2)确定共享API2的目标CCF实体为CCF实体1,并确定共享信息包括域内目标CCF实体信息,其中域内目标CCF实体信息包括CCF实体1的信息。在一些示例中,API发布实体(API发布实体2)确定共享API2的目标CCF实体为CCF实体1,并确定共享信息包括目标CCF实体的信息,即包括CCF实体1的信息。
在又一种实现方式中,API发布实体(API发布实体2)确定共享API3的目标CCF实体包括CCF实体1和CCF实体3;并确定共享信息包括域内目标CCF实体信息和目标域指示信息,其中,域内目标CCF实体信息包括CCF实体1的信息,目标域指示信息指示信任域B(CCF实体3所属域)。在一些示例中,API发布实体(API发布实体2)确定共享API3的目标CCF实体包括CCF实体1和CCF实体3,并确定共享信息包括目标CCF实体(CCF实体2和CCF实体3)的信息。
S402、API发布实体向第一CCF实体发送第一API发布请求。
API发布实体向第一CCF实体发送第一API发布请求,第一API发布请求包括API的信息和API的共享信息。示例性的,第一API发布请求消息可以是服务API发布请求(service API publish request),或者服务API配置请求(service API configuration request)。
在一种实现方式中,一条第一API发布请求包括一个API的信息以及该API的共享信息。比如,第一API发布请求包括API1的信息以及API1的共享信息。第一CCF实体根据API1的共享信息共享API1,待共享API为API1。
在一种实现方式中,一条第一API发布请求包括多个API的信息以及分别与每个API对应的共享信息。比如,第一API发布请求包括API1的信息与API1的共享信息,API2的信息与API2的共享信息,API3的信息与API3的共享信息。第一CCF实体分别根据每个API的共享信息共享各个API,比如,第一CCF实体根据API1的共享信息共享API1,根据API2的共享信息共享API2,根据API3的共享信息共享API3。待共享API为API1、API2和API3。
在一种实现方式中,一条第一API发布请求包括多个API的信息以及与多个API对应的一个共享信息。比如,第一API发布请求包括API1的信息、API2的信息和API3的信息以及共享信息,第一CCF实体根据该共享信息共享API1、API2和API3。待共享API为API1、API2和API3。
在一种实现方式中,API的信息可以包括API的共享信息,即API的共享信息可以作为API的一个属性。比如,API的信息可以包括API的标识、API的类型、以及API的共享信息。在另一种实现方式中,API的信息和API的共享信息可以分别是单独的信息。本申请实施例对此不进行限定。
本申请实施例以一条第一API发布请求包括一个API的信息以及该API的共享信息为例进行说明。本领域技术人员可以理解,第一API发布请求包括一个API的信息以及该API的共享信息的技术方案同样适用于一条第一API发布请求包括多个API的信息以及分别与每个API对应的共享信息,以及一条第一API发布请求包括多个API的信息以及与多个API对应的一个共享信息的场景,本申请实施例中不再赘述。
S403、第一CCF实体接收第一API发布请求。
第一CCF实体接收第一API发布请求后,可以保存接收到的API的信息。
S404、第一CCF实体向API发布实体发送第一API发布响应消息。
第一CCF实体向API发布实体发送第一API发布响应消息。在一种示例中,第一API发布响应消息可以包括发布结果指示信息,用于指示API发布成功或者API发布失败。示例性的,API发布响应消息可以是服务API发布响应(service API publish response),或者服务API配置响应(service API configuration response)。
S405、API发布实体接收第一API发布响应消息。
本申请实施例提供的API发布方法,API发布实体可以在向第一CCF实体发送的API发布请求消息中指示是否共享API,更进一步还可以指示待共享API的目标CCF,这样,第一CCF实体可以根据共享信息向其他CCF实体共享待共享API的信息,实现将API发布到多个CCF实体。这样,API调用实体可以通过多个CCF实体发现并获取到API。
实施例三:
本申请实施例提供一种API发布方法。如图5所示,该方法可以包括如下步骤:
S501、第一CCF实体确定待共享API以及待共享API的目标CCF实体。
第一CCF实体确定待共享API以及待共享API的目标CCF实体,其中,目标CCF实体可以包括第一目标CCF实体,和/或第二目标CCF实体,其中,第一目标CCF实体所属域与第一CCF实体所属域相同,第二目标CCF实体所属域与第一CCF实体所属域不同。
方式一:
第一CCF实体根据接收到的第一API发布请求确定待共享API以及待共享API的目标CCF实体。其中,第一API发布请求包括API的信息和共享信息。
在一种实现方式中,第一CCF实体根据API的信息和共享信息确定待共享API。当第一API发布请求中包括该API的共享信息,则确定第一API发布请求中的API的信息指示的API为待共享API。在另一种实现方式中,第一CCF实体根据第一API发布请求中的API的信息和第六预设规则确定待共享API。示例性的,第六预设规则可以包括根据商业签约信息与发布的目标CCF实体的映射关系确定待共享API,或根据API的类型, 或根据API的类型,或根据API类型与发布的目标CCF实体的映射关系确定待共享API等。第一CCF实体根据第六预设规则确定待共享API的具体方法可参考实施例二S401中API发布实体根据第五预设规则确定待共享API的目标CCF实体的描述,此处不再赘述。当然,第一CCF实体还可以采用其他方式,例如,根据其他预设规则,确定待共享API,本申请实施例对此不进行限定。
在一种实现方式中,第一CCF实体根据共享信息确定待共享API的目标CCF实体。
在一种示例中,共享信息为共享指示信息,第一CCF实体根据第一预设规则确定目标CCF实体。示例性的,第一预设规则可以包括根据商业签约信息与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的域的映射关系)确定共享API的目标CCF实体,或根据API的类型与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的逻辑域或者地理区域的映射关系)确定共享API的目标CCF实体等。第一CCF实体根据第一预设规则确定目标CCF实体的具体方法可参考实施例二S401中API发布实体根据第五预设规则确定API发布范围的描述,此处不再赘述。当然,第一CCF实体还可以采用其他方式,例如,根据其他预设规则,确定待共享API的目标CCF实体,本申请实施例对此不进行限定。
在另一种示例中,共享信息包括域内目标CCF实体信息,(比如,共享信息为域内目标CCF实体信息,或者共享信息为共享指示信息和域内目标CCF实体信息),第一CCF实体根据域内目标CCF实体信息确定第一目标CCF实体。比如,域内目标CCF实体信息包括CCF实体2的信息,第一CCF实体确定第一目标CCF实体包括CCF实体2。
在另一种示例中,共享信息包括目标域指示信息,(比如,共享信息为目标域指示信息;或者,共享信息包括共享指示信息和目标域指示信息),第一CCF实体根据目标域指示信息确定第二目标CCF实体。比如,目标域指示信息为目标域的标识,第一CCF实体根据第二预设规则,在目标域内确定第二目标CCF实体。示例性的,第二预设规则为,目标CCF实体为目标域的域边界的CCF实体。例如,目标域指示信息为图1中信任域B的标识,信任域B的域边界的CCF实体为CCF实体3,第一CCF实体确定第二目标CCF实体包括CCF实体3。再比如,目标域指示信息包括目标域的标识和域外目标CCF实体信息,第一CCF实体根据域外目标CCF实体信息,在目标域内确定第二目标CCF实体。例如,目标域的标识为图1中信任域B的标识,域外目标CCF实体信息包括CCF实体3的信息,第一CCF实体确定第二目标CCF实体包括信任域B中的CCF实体3。
在另一种示例中,共享信息包括共享指示信息、域内目标CCF实体信息和目标域指示信息;第一CCF实体根据域内目标CCF实体信息确定第一目标CCF实体,并根据目标域指示信息确定第二目标CCF实体。示例性的,共享指示信息为一个数值,第一CCF实体根据共享指示信息的值确定目标CCF实体。比如,如果共享指示信息为“00”,表示待共享API共享给第一CCF实体所属域内的CCF实体,第一CCF实体将域内目标CCF实体信息指示的CCF实体确定为目标CCF实体;如果共享指示信息为“01”,表示待共享API共享给第一CCF实体所属域外的CCF实体,第一CCF实体将目标域指示信息指示的CCF实体确定为目标CCF实体。
在另一种示例中,共享信息包括目标CCF实体的信息,(比如,共享信息为目标CCF 实体的信息,或者共享信息为共享指示信息和目标CCF实体的信息,或者共享信息为共享指示信息、目标CCF实体的信息和目标域指示信息,或者共享信息为目标CCF实体的信息和目标域指示信息),第一CCF实体根据目标CCF实体的信息确定目标CCF实体。比如,第一CCF实体可以将目标CCF实体的信息指示的CCF实体确定为目标CCF实体,该目标CCF实体可以包括第一目标CCF实体,和/或,第二目标CCF实体。比如,目标CCF实体的信息包括CCF实体2的信息,第一CCF实体确定目标CCF实体包括CCF实体2;比如,目标CCF实体的信息包括CCF实体3的信息,第一CCF实体确定目标CCF实体包括CCF实体3;比如,目标CCF实体的信息包括CCF实体2和CCF实体3的信息,第一CCF实体确定目标CCF实体包括CCF实体2和CCF实体3。
方式二:
第一CCF实体根据第三预设规则确定待共享API;进一步的,第一CCF实体根据第四预设规则确定目标CCF实体。
在一种实现方式中,第一CCF实体根据第三预设规则从本地保存的API中获取待共享API,并根据第四预设规则确定本地保存的API中待共享API的目标CCF实体。其中,示例性的,本地保存的API的信息可以是第一CCF实体从API发布实体接收到的API的信息后,保存的API的信息。示例性的,该API的信息可以是第一CCF实体从API发布实体的第三API发布请求消息中获取的。
示例性的,第三预设规则可以包括根据商业签约信息与发布的目标CCF实体的映射关系确定待共享API,或根据API的类型,或API的类型与发布的目标CCF实体的映射关系确定待共享API等。第一CCF实体根据第三预设规则确定待共享API的具体方法可参考实施例二S401中API发布实体根据第五预设规则确定API发布范围的描述,此处不再赘述。当然,第一CCF实体还可以采用其他方式,例如,根据其他预设规则,确定待共享API,本申请实施例对此不进行限定。
示例性的,第四预设规则可以包括根据商业签约信息与发布的目标CCF实体的映射关系确定目标CCF实体,或根据API的类型,或API的类型与发布的目标CCF实体的映射关系确定目标CCF实体等。第一CCF实体根据第四预设规则确定目标CCF实体的具体方法可参考实施例二S401中API发布实体根据第五预设规则确定API发布范围的描述,此处不再赘述。当然,第一CCF实体还可以采用其他方式,例如,根据其他预设规则,确定目标CCF实体,本申请实施例对此不进行限定。
S502、第一CCF实体向目标CCF实体共享API的信息。
在一种实现方式中,第一CCF实体向目标CCF实体发送第二API发布请求,第二API发布请求包括API的信息。示例性的,第二API发布请求消息可以是服务API发布请求(service API publish request),或者服务API配置请求(service API configuration request),或者互联API发布请求(interconnection API publish request)。
在一种实现方式中,如果第一CCF实体确定向第二目标CCF实体共享API,第一CCF实体可以将待共享API的信息修改为全局信息,并在第一CCF实体向第二目标CCF实体共享API的信息时,携带该API的全局信息。比如,第一CCF实体将API的本地标识修改为全局标识,将API的本地接口地址修改为全局地址。
在一种实现方式中,如果第一CCF实体确定向第二目标CCF实体共享API,第一CCF 实体可以对待共享API执行拓扑隐藏,即对于每个待共享API,选择一个AEF实体作为拓扑隐藏入口点,将待共享API的接口信息替换为拓扑隐藏入口点AEF实体的信息。
S503、目标CCF实体接收API的信息。
在一种实现方式中,目标CCF实体接收第二API发布请求,第二API发布请求中包括API的信息,目标CCF实体可以保存接收到的API的信息。
S504、目标CCF实体向第一CCF实体发送第二API发布响应消息。
在一种实现方式中,目标CCF实体向第一CCF实体发送第二API发布响应消息。在一种示例中,第二API发布响应消息可以包括发布结果指示信息,用于指示API发布成功或者API发布失败。示例性的,API发布响应消息可以是服务API发布响应(service API publish response),或者服务API配置响应(service API configuration response),或者互联API发布响应(interconnection API publish response)。
S505、第一CCF实体接收第二API发布响应消息。
需要说明的是,实际应用中,可以根据需要在上述各个实施例中删除一些步骤,或者增加一些步骤,并且本申请实施例并不限定上述各个步骤的先后顺序。在一些实现方式中,还可以将上述实施例二和实施例三的步骤进行合并。比如,如果实施例三S501中,第一CCF实体采用方式一,即根据接收到的第一API发布请求确定待共享API以及待共享API的目标CCF实体,则实施例二和实施例三的步骤可以合并。在这种方式中,第一CCF实体可以在S404向API发布实体发送第一API发布响应消息;或者不执行S404,在S505,第一CCF实体接收第二API发布响应消息之后,再向API发布实体发送第一API发布响应消息。
进一步的,每个CCF实体接收到API的信息之后,还可以分别向订阅了API的API调用实体发送通知消息,通知API调用实体有新的API或者有API调用实体感兴趣的API。
本申请实施例提供的API发布方法,第一CCF实体可以确定将API共享到其他的CCF实体,实现将API发布到多个CCF实体。这样,API调用实体可以通过多个CCF实体发现并获取到API。
实施例四:
本申请实施例提供一种API发布方法。如图5A所示,该方法可以包括如下步骤:
S601、API发布实体确定API的信息以及API的共享信息。
API发布实体确定API的信息,该API为待共享API,并确定该API的共享信息。
其中,API发布实体可以是APF实体,或者,API发布实体也可以是APIMF实体,当然API发布实体还可以是CAPIF系统架构中的其他实体,本申请实施例对此不进行限定。本申请实施例中以API发布实体为APF实体为例进行说明。
API发布实体可以根据用户的指令获取待共享API以及待共享API的目标CCF实体;也可以根据预设规则确定待共享的API以及待共享API的目标CCF实体;具体方法可以参考S401的描述,此处不再赘述。
在一种实现方式中,API发布实体确定是否共享该API。如果API发布实体确定共享该API,则确定该待共享API的共享信息,其中,API的共享信息用于指示第一CCF实体共享待共享的API。
在一种实现方式中,共享信息可以包括共享范围指示信息,共享范围指示信息用 于指示待共享API的共享范围,其中,待共享API的共享范围可以包括第一CCF实体所属域内的CCF实体,和/或第一CCF实体所属域外的CCF实体。示例性的,共享范围指示信息的值为0,表示待共享API的共享范围为,第一CCF实体所属域内的CCF实体;共享范围指示信息的值为1,表示待共享API的共享范围为,第一CCF实体所属域外的CCF实体;共享范围指示信息的值为2,表示待共享API的共享范围包括:第一CCF实体所属域内的CCF实体和第一CCF实体所属域外的CCF实体。
在一种实现方式中,共享信息还可以包括目标CCF实体的信息,其中包括第一CCF实体所属域内的CCF实体的信息,和/或第一CCF实体所属域外的CCF实体的信息。其中,目标CCF实体的信息可以为,目标CCF实体的标识、FQDN域名、IP地址或者IP地址和端口号,或者为URL等。
当共享范围指示信息表示,待共享API的共享范围为,第一CCF实体所属域内的CCF实体;则目标CCF实体的信息包括第一CCF实体所属域内的CCF实体的信息。当共享范围指示信息表示,待共享API的共享范围为,第一CCF实体所属域外的CCF实体;则目标CCF实体的信息包括第一CCF实体所属域外的CCF实体的信息。当共享范围指示信息表示,待共享API的共享范围为,第一CCF实体所属域内的CCF实体和第一CCF实体所属域外的CCF实体;则目标CCF实体的信息包括第一CCF实体所属域内的CCF实体的信息和第一CCF实体所属域外的CCF实体的信息。
在一种实现方式中,共享信息还可以包括目标域指示信息,目标域指示信息用于指示目标CCF实体所属的目标域,该目标域与第一CCF实体所属域不同。其中,目标域指示信息可以是目标域的标识,比如PLMN ID,域名(如domain.com);或者,目标域指示信息还可以包括目标域的标识和目标CCF实体的信息,其中,目标CCF实体的信息可以为CCF实体的标识,可以是FQDN域名,IP地址,或者IP地址和端口号,或者为URL等。待共享API的共享范围待共享API的共享范围待共享API的共享范围。
示例性的,图1中信任域A为运营商A的PLMN网络域,CCF实体1为运营商A部署在西安地区的CCF实体,用于管理西安地区的AEF实体提供的API,CCF实体2是运营商A部署宁夏地区的的CCF实体,用于管理宁夏地区的AEF实体提供的API,API发布实体1为西安地区的运营商A,API发布实体2为宁夏地区的运营商A;信任域B为运营商B的PLMN网络域。API发布实体(API发布实体1)确定将API1发布至CCF实体1;确定将API2共享至宁夏地区,则确定将API2发布至CCF实体1,并由CCF实体1发布至CCF实体2;确定将API3共享至宁夏地区以及运营商B的PLMN网络域,则确定将API3发布至CCF实体1,并由CCF实体1发布至CCF实体2和CCF实体3;继而,API发布实体1可以确定不指定共享API1,指定待共享API包括API2和API3;并且,API发布实体1确定API2和API3的共享信息。
在一种实现方式中,API发布实体(API发布实体1)确定共享信息为共享范围指示信息。该共享范围指示信息指示API2的共享范围为第一CCF实体(CCF实体1)所属域(信任域A)内的CCF实体;此时由第一CCF实体确定共享API2的目标CCF实体,该目标CCF实体是该第一CCF实体所属域(信任域A)内的CCF实体。该共享范围指示信息指示API3的共享范围为第一CCF实体(CCF实体1)所属域(信任域A)内的CCF 实体,以及第一CCF实体(CCF实体1)所属域(信任域A)外的CCF实体;此时由第一CCF实体确定共享API3的目标CCF实体,该目标CCF实体包括该第一CCF实体所属域(信任域A)内的CCF实体,以及第一CCF实体(CCF实体1)所属域(信任域A)外的CCF实体。
在一种实现方式中,API发布实体(API发布实体1)确定共享信息为共享范围指示信息以及目标CCF实体的信息。API发布实体(API发布实体1)确定API2对应的共享信息包括:共享范围指示信息,指示API2的共享范围为第一CCF实体(CCF实体1)所属域(信任域A)内的CCF实体;目标CCF实体的信息包括CCF实体2的信息。API发布实体(API发布实体1)确定API3对应的共享信息包括:共享范围指示信息,指示API3的共享范围为,第一CCF实体(CCF实体1)所属域(信任域A)内的CCF实体,以及第一CCF实体(CCF实体1)所属域(信任域A)外的CCF实体;目标CCF实体的信息包括CCF实体2的信息,以及CCF实体3的信息。
在一种实现方式中,API发布实体(API发布实体1)确定共享信息包括目标域指示信息。示例性的,API发布实体(API发布实体1)确定API3对应的共享信息包括:共享范围指示信息,指示API3的共享范围为,第一CCF实体(CCF实体1)所属域(信任域A)内的CCF实体,以及第一CCF实体(CCF实体1)所属域(信任域A)外的CCF实体;目标CCF实体的信息包括CCF实体2的信息,目标域指示信息包括信任域B的信息。
S602、API发布实体向第一CCF实体发送第一API发布请求。
API发布实体向第一CCF实体发送第一API发布请求,第一API发布请求包括API的信息和API的共享信息。具体描述可参考S402,此处不再赘述。
S603、第一CCF实体接收第一API发布请求。
第一CCF实体接收第一API发布请求,其中包括API的信息和API的共享信息。
第一CCF实体根据API的信息确定待共享API;确定第一API发布请求中的API的信息指示的API为待共享API。比如,API的信息包括API2的信息,和API3的信息,则确定待共享API包括API2和API3。
第一CCF实体根据API的共享信息,确定待共享API的目标CCF实体。其中,目标CCF实体可以包括第一目标CCF实体,和/或第二目标CCF实体,其中,第一目标CCF实体所属域与第一CCF实体所属域相同,第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种实现方式中,共享信息为共享范围指示信息,共享范围指示信息指示待共享API的共享范围;其中,待共享API的共享范围包括第一CCF实体所属域内的CCF实体,和/或,第一CCF实体所属域外的CCF实体。第一CCF实体根据共享范围指示信息确定待共享API的共享范围;如果共享范围为第一CCF实体所属域内的CCF实体,第一CCF实体在第一CCF实体所属域内的CCF实体中确定目标CCF实体;如果共享范围为第一CCF实体所属域外的CCF实体,第一CCF实体在第一CCF实体所属域外的CCF实体中确定目标CCF实体;如果共享范围包括第一CCF实体所属域内的CCF实体,和第一CCF实体所属域外的CCF实体,第一CCF实体在第一CCF实体所属域内的CCF实体中确定第一目标CCF实体,并且在第一CCF实体所属域外的CCF实体中确定第二 目标CCF实体,目标CCF实体包括第一目标CCF实体和第二目标CCF实体。
在一些实例中,待共享API的共享范围为第一CCF实体所属域内的CCF实体,第一CCF实体根据第七预设规则在第一CCF实体所属域内的CCF实体中确定目标CCF实体,该目标CCF实体为第一目标CCF实体;在一些实例中,待共享API的共享范围为第一CCF实体所属域外的CCF实体,第一CCF实体根据第八预设规则在第一CCF实体所属域外的CCF实体中确定目标CCF实体,该目标CCF实体为第二目标CCF实体;在一些实例中,待共享API的共享范围包括第一CCF实体所属域内的CCF实体,和第一CCF实体所属域外的CCF实体,第一CCF实体根据第七预设规则在第一CCF实体所属域内的CCF实体中确定第一目标CCF实体,并且根据第八预设规则在第一CCF实体所属域外的CCF实体中确定第二目标CCF实体。
示例性的,第一CCF实体(CCF实体1)从API发布实体(API发布实体1)接收到第一API发布请求,其中包括API2的信息,以及对应的共享范围指示信息的值为0,表示API2的共享范围为,第一CCF实体所属域(信任域A)内的CCF实体。第一CCF实体(CCF实体1)根据第七预设规则在信任域A内确定目标CCF实体。在一种示例中,第七预设规则为,目标CCF实体包括第一CCF实体所属域(信任域A)内全部CCF实体;则确定目标CCF实体包括CCF实体2。在一种示例中,第七预设规则为,商业签约信息与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的域的映射关系),或API的类型,或API的类型与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的逻辑域或者地理区域的映射关系)等。比如,第七预设规则可以是将IoT类型的API共享至CCF2,则当API2为IoT类型的API,第一CCF实体(CCF实体1)确定将API2共享至CCF实体2,即目标CCF实体包括CCF实体2。当然,第一CCF实体还可以采用其他方式,例如,根据其他预设规则,确定目标CCF实体,本申请实施例对此不进行限定。
示例性的,第一API发布请求还包括API3的信息,以及对应的共享范围指示信息的值为2,表示API3的共享范围包括:第一CCF实体所属域内的CCF实体和第一CCF实体所属域外的CCF实体。第一CCF实体根据第七预设规则在第一CCF实体所属域内确定第一目标CCF实体,并且根据第八预设规则在第一CCF实体所属域外确定第二目标CCF实体。在一种示例中,第八预设规则包括,商业签约信息与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的域的映射关系),或API的类型,或API的类型与发布的目标CCF实体的映射关系(也可以理解为API的类型与目标CCF实体的逻辑域或者地理区域的映射关系)等。比如,运营商B与运营商A有API共享使用的签约,即对于运营商A的任何一个API,运营商B都可以获取并使用该API。第一CCF实体(CCF实体1)根据运营商A与运营商B的API共享使用的签约信息确定将该API发布至运营商B对应的信任域(示例性的,图1中CCF实体3)。比如,第八预设规则可以是将V2X类型的API共享至CCF3,则当API3为V2X类型的API,第一CCF实体(CCF实体1)确定将API3共享至CCF实体3。当然,第一CCF实体还可以采用其他方式,例如,根据其他预设规则,确定第二目标CCF实体,本申请实施例对此不进行限定。
需要说明的是,第七预设规则和第八预设规则可以是对应的规则,比如,第七预设规则为根据API的类型确定目标CCF实体,第八预设规则为根据API的类型确定目标CCF 实体;第七预设规则和第八预设规则也可以是不对应的规则,比如,第七预设规则为根据API的类型确定目标CCF实体,第八预设规则为根据商业签约信息与发布的目标CCF实体的映射关系确定目标CCF实体。本申请实施例对此不进行限定。
在一种实现方式中,共享信息包括共享范围指示信息和目标CCF实体的信息。
在一种示例中,共享范围指示信息指示待共享API的共享范围为第一CCF实体所属域内的CCF实体,第一CCF实体将目标CCF实体的信息指示的CCF实体确定为目标CCF实体,该目标CCF实体为第一CCF实体所属域内的CCF实体。比如,API2对应的共享信息包括:共享范围指示信息,指示API2的共享范围为第一CCF实体(CCF实体1)所属域(信任域A)内的CCF实体;目标CCF实体的信息包括CCF实体2的信息;第一CCF实体将CCF实体2确定为目标CCF实体。
在一种示例中,共享范围指示信息指示待共享API的共享范围为,第一CCF实体所属域外的CCF实体,第一CCF实体将目标CCF实体的信息指示的CCF实体确定为目标CCF实体,该目标CCF实体为第一CCF实体所属域外的CCF实体。比如,API4对应的共享信息包括:共享范围指示信息,指示API4共享范围为,第一CCF实体(CCF实体1)所属域(信任域A)外CCF实体;目标CCF实体的信息包括CCF实体3的信息;第一CCF实体将CCF实体3确定为目标CCF实体。
在一种示例中,共享范围指示信息指示待共享API的共享范围为,第一CCF实体所属域内的CCF实体,以及第一CCF实体所属域外的CCF实体,第一CCF实体将目标CCF实体的信息指示的CCF实体确定为目标CCF实体,该目标CCF实体包括第一CCF实体所属域内的CCF实体和第一CCF实体所属域外的CCF实体。比如,API3对应的共享信息包括:共享范围指示信息,指示API3共享范围为,第一CCF实体(CCF实体1)所属域(信任域A)内的CCF实体,以及第一CCF实体(CCF实体1)所属域(信任域A)外的CCF实体;目标CCF实体的信息包括CCF实体2的信息,以及CCF实体3的信息;第一CCF实体将CCF实体2确定为第一目标CCF实体,将CCF实体3确定为第二目标CCF实体,目标CCF实体包括第一目标CCF实体和第二目标CCF实体。
在一种实现方式中,共享信息还包括目标域指示信息,目标域指示信息用于指示目标CCF实体所属的目标域。第一CCF实体在目标域内的CCF实体中确定第二目标CCF实体。
比如,目标域指示信息为目标域的标识,第一CCF实体根据第二预设规则,在目标域内确定第二目标CCF实体。示例性的,第二预设规则为,目标CCF实体为目标域的域边界的CCF实体。例如,目标域指示信息为图1中信任域B的标识,信任域B的域边界的CCF实体为CCF实体3,第一CCF实体确定第二目标CCF实体包括CCF实体3。再比如,目标域指示信息包括目标域的标识和域外目标CCF实体信息,第一CCF实体根据域外目标CCF实体信息,在目标域内确定第二目标CCF实体。例如,目标域的标识为图1中信任域B的标识,域外目标CCF实体信息包括CCF实体3的信息,第一CCF实体确定第二目标CCF实体包括信任域B中的CCF实体3。
需要说明的是,第一CCF实体所属域外的CCF实体的信息可以通过共享信息中的目标CCF实体的信息指示,也可以通过共享信息中的目标域指示信息指示,本申请实施例对此不进行限定。
S604、第一CCF实体向目标CCF实体共享API的信息。
第一CCF实体向目标CCF实体共享API的信息的方法可以参考S502的描述,此处不再赘述。
S605、目标CCF实体接收API的信息。
目标CCF实体接收API的信息之后的操作步骤,可以参考S503的描述,此处不再赘述。
S606、目标CCF实体向第一CCF实体发送第二API发布响应消息。
目标CCF实体向第一CCF实体发送第二API发布响应消息的方法,可以参考S504的描述,此处不再赘述。
S607、第一CCF实体接收第二API发布响应消息。
需要说明的是,实际应用中,可以根据需要在上述各个实施例中删除一些步骤,或者增加一些步骤,并且本申请实施例并不限定上述各个步骤的先后顺序。
进一步的,每个CCF实体接收到API的信息之后,还可以分别向订阅了API的API调用实体发送通知消息,通知API调用实体有新的API或者有API调用实体感兴趣的API。
本申请实施例提供的API发布方法,第一CCF实体可以根据API发布实体的指示信息,确定将API共享到其他的CCF实体,实现将API发布到多个CCF实体。这样,API调用实体可以通过多个CCF实体发现并获取到API。
上述主要从API发布实体和CCF实体交互的角度对本申请实施例提供的方案进行了介绍。可以理解的是,API发布实体和CCF实体为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
本申请实施例可以根据上述方法示例对API发布实体和CCF实体进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。下面以采用对应各个功能划分各个功能模块为例进行说明。
图6是本申请实施例提供的装置600的结构示意图,装置600可以是CCF实体,能够实现本申请实施例提供的方法中第一CCF实体的功能;装置600也可以是能够支持CCF实体实现本申请实施例提供的方法中第一CCF实体的功能的装置。装置600可以是硬件结构、软件模块、或硬件结构加软件模块。装置600可以由芯片系统实现。本申请实施例中,芯片系统可以由芯片构成,也可以包含芯片和其他分立器件。如图6所示,装置600包括处理模块601和发送模块602。
处理模块601,用于确定待共享API。
发送模块602,用于向待共享API的目标CCF实体共享待共享API的信息。
在一种实现方式中,如图7所示,该装置600还包括:接收模块603。
接收模块603,用于接收第一API发布请求,其中包括API的信息和API的共享信息。
处理模块601,具体用于根据第一API发布请求,确定待共享API。
在一种实现方式中,处理模块601,还用于根据共享信息,确定目标CCF实体。
在一种实现方式中,共享信息包括共享指示信息、目标CCF实体的信息或目标域指示信息中至少一个;其中,共享指示信息用于指示共享待共享API;目标域指示信息用于指示目标域,该目标域与第一CCF实体所属域不同。
在一种实现方式中,共享信息包括共享指示信息,处理模块601用于根据第一预设规则确定所述目标CCF实体;或者,共享信息包括目标CCF实体的信息,处理模块601用于根据目标CCF实体的信息确定目标CCF实体;或者,共享信息包括目标域指示信息,处理模块601用于根据目标域指示信息确定第二目标CCF实体,其中,第二目标CCF实体为目标CCF实体中一个或多个,第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种实现方式中,共享信息包括共享范围指示信息;共享范围指示信息用于指示待共享API的共享范围。
在一种实现方式中,待共享API的共享范围为第一CCF实体所属域内的CCF实体,处理模块601用于在第一CCF实体所属域内的CCF实体中确定目标CCF实体。
在另一种实现方式中,待共享API的共享范围为第一CCF实体所属域外的CCF实体,处理模块601用于在第一CCF实体所属域外的CCF实体中确定目标CCF实体。
在另一种实现方式中,待共享API的共享范围包括第一CCF实体所属域内的CCF实体,和第一CCF实体所属域外的CCF实体,处理模块601用于在第一CCF实体所属域内的CCF实体中确定第一目标CCF实体,并且在第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,其中,目标CCF实体包括第一目标CCF实体和第二目标CCF实体。
其中,第一目标CCF实体为目标CCF实体中一个或多个,第一目标CCF实体所属域与第一CCF实体所属域相同;第二目标CCF实体为目标CCF实体中一个或多个,第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种实现方式中,共享信息还包括目标域指示信息;其中,目标域指示信息用于指示目标CCF实体所属的目标域。
在一种实现方式中,处理模块601在第一CCF实体所属域外的CCF实体中确定目标CCF实体,具体包括:处理模块601在目标域内的CCF实体中确定目标CCF实体。
在另一种实现方式中,处理模块601在第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,具体包括:处理模块601在目标域内的CCF实体中确定第二目标CCF实体。
在一种实现方式中,目标域指示信息为目标域的标识,处理模块601具体用于根据第二预设规则,在目标域内确定第二目标CCF实体;或者,目标域指示信息包括目标域的标识和域外目标CCF实体信息,处理模块601具体用于根据域外目标CCF实体信息,在目标域内确定第二目标CCF实体。
在一种实现方式中,处理模块601具体用于:根据第三预设规则,确定待共享API。
在一种实现方式中,处理模块601具体用于:根据第四预设规则,确定目标CCF实体。
在一种实现方式中,目标CCF实体包括第一目标CCF实体,和/或第二目标CCF实体; 其中,第一目标CCF实体所属域与第一CCF实体所属域相同;第二目标CCF实体所属域与第一CCF实体所属域不同。
在一种实现方式中,发送模块602向待共享API的目标CCF实体共享待共享API的信息,具体包括:发送模块602向第二目标CCF实体共享待共享API的信息,其中,待共享API的信息为全局信息。
在一种实现方式中,该待共享API的信息包括待共享API的接口信息,其中,该接口信息为拓扑隐藏入口点的信息。
需要说明的是,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,例如,处理模块601至少可以用于执行图3中的S301,或图5中的S501,或图5A中的S603,和/或执行本申请中描述的其他步骤。发送模块602至少可以用于执行图3中的S302,或图4中的S404,或图5中的S502,或图5A中的S604,和/或执行本申请中描述的其他步骤。接收模块603至少可以用于执行图4中的S403,或图5中的S505,或图5A中的S603、S607,和/或执行本申请中描述的其他步骤,在此不再赘述。
图8是本申请实施例提供的装置700的结构示意图,装置700可以是API发布实体,能够实现本申请实施例提供的方法中API发布实体的功能;装置700也可以是能够支持API发布实体实现本申请实施例提供的方法中API发布实体的功能的装置。装置700可以是硬件结构、软件模块、或硬件结构加软件模块。如图8所示,装置700包括处理模块701和发送模块702。
处理模块701,用于确定API的信息以及API的共享信息,共享信息用于指示第一CCF实体共享API。
发送模块702,用于向第一CCF实体发送第一API发布请求,其中,第一API发布请求包括API的信息和API的共享信息。
在一种实现方式中,共享信息包括共享指示信息、目标CCF实体的信息或目标域指示信息中至少一个;其中,共享指示信息用于指示共享待共享API;目标域指示信息用于指示目标域,该目标域与第一CCF实体所属域不同。
在一种实现方式中,共享信息包括共享范围指示信息;共享范围指示信息用于指示待共享API的共享范围。
在一种实现方式中,共享信息还包括目标域指示信息,目标域指示信息用于指示目标CCF实体所属的目标域。
在一种实现方式中,目标域指示信息为目标域的标识;或者,目标域指示信息包括目标域的标识和域外目标CCF实体信息,其中,域外目标CCF实体信息用于指示待共享API在目标域内的目标CCF实体信息。
需要说明的是,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,例如,处理模块701至少可以用于执行图4中的S401,或图5A中的S601,和/或执行本申请中描述的其他步骤。发送模块702至少可以用于执行图4中的S402,或图5A中的S602,和/或执行本申请中描述的其他步骤,在此不再赘述。
在本实施例中,装置600或装置700可以以采用集成的方式划分各个功能模块的形式来呈现。这里的“模块”可以指特定ASIC,电路,执行一个或多个软件或固件程序的处理器和存储设备,集成逻辑电路,和/或其他可以提供上述功能的器件。
在一个简单的实施例中,装置600或装置700可以采用图2所示的形式。
在本申请的一个示例中,图6或图7中的处理模块601,或图8中的处理模块701可以通过处理器201或处理器208实现;图6或图7中的发送模块602,或图7中的接收模块603,或图8中的发送模块702,可以通过通信接口204实现。
由于本申请实施例提供的装置可用于执行上述API发布方法,因此其所能获得的技术效果可参考上述方法实施例,在此不再赘述。
本领域普通技术人员可知,上述方法中的全部或部分步骤可以通过程序指令相关的硬件完成,该程序可以存储于一计算机可读存储介质中,该计算机可读存储介质如ROM、RAM和光盘等。
本申请实施例还提供一种存储介质,该存储介质可以包括存储器203。
上述提供的任一种装置中相关内容的解释及有益效果均可参考上文提供的对应的方法实施例,此处不再赘述。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件程序实现时,可以全部或部分地以计算机程序产品的形式来实现。该计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行计算机程序指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、网络设备、用户设备、或者其他可编程装置。所述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或者数据中心通过有线(例如同轴电缆、光纤、数字用户线(digital subscriber line,DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可以用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质(例如,软盘、硬盘、磁带),光介质(例如,数字视频光盘(digital video disc,DVD))、或者半导体介质(例如固态硬盘(solid state disk,SSD))等。
尽管在此结合各实施例对本申请进行了描述,然而,在实施所要求保护的本申请过程中,本领域技术人员通过查看所述附图、公开内容、以及所附权利要求书,可理解并实现所述公开实施例的其他变化。在权利要求中,“包括”(comprising)一词不排除其他组成部分或步骤,“一”或“一个”不排除多个的情况。单个处理器或其他单元可以实现权利要求中列举的若干项功能。相互不同的从属权利要求中记载了某些措施,但这并不表示这些措施不能组合起来产生良好的效果。
尽管结合具体特征及其实施例对本申请进行了描述,显而易见的,在不脱离本申请的精神和范围的情况下,可对其进行各种修改和组合。相应地,本说明书和附图仅仅是所附权利要求所界定的本申请的示例性说明,且视为已覆盖本申请范围内的任意和所有修改、变化、组合或等同物。显然,本领域的技术人员可以对本申请进行各种改动和变型而不脱离本申请的精神和范围。这样,倘若本申请的这些修改和变型属于本申请权利要求及其等同技术的范围之内,则本申请也意图包含这些改动和变型在内。

Claims (42)

  1. 一种API发布方法,其特征在于,包括:
    第一通用应用程序接口核心CCF实体确定待共享应用程序接口API;
    所述第一CCF实体向所述待共享API的目标CCF实体共享所述待共享API的信息。
  2. 根据权利要求1所述的方法,其特征在于,所述第一CCF实体确定待共享API,包括:
    所述第一CCF实体接收第一API发布请求,所述第一API发布请求包括API的信息和所述API的共享信息;
    所述第一CCF实体根据所述第一API发布请求,确定所述待共享API。
  3. 根据权利要求2所述的方法,其特征在于,所述方法还包括:
    所述第一CCF实体根据所述共享信息,确定所述目标CCF实体。
  4. 根据权利要求3所述的方法,其特征在于,所述共享信息包括共享指示信息、所述目标CCF实体的信息或目标域指示信息中至少一个;
    其中,所述共享指示信息用于指示共享所述待共享API;所述目标域指示信息用于指示目标域,所述目标域与所述第一CCF实体所属域不同。
  5. 根据权利要求4所述的方法,其特征在于,所述第一CCF实体根据所述共享信息,确定所述目标CCF实体,包括:
    所述共享信息包括所述共享指示信息,所述第一CCF实体根据第一预设规则确定所述目标CCF实体;或者,
    所述共享信息包括所述目标CCF实体的信息,所述第一CCF实体根据所述目标CCF实体的信息确定所述目标CCF实体;或者,
    所述共享信息包括所述目标域指示信息,所述第一CCF实体根据所述目标域指示信息确定第二目标CCF实体,所述第二目标CCF实体为所述目标CCF实体中一个或多个,所述第二目标CCF实体所属域与所述第一CCF实体所属域不同。
  6. 根据权利要求3所述的方法,其特征在于,
    所述共享信息包括共享范围指示信息,所述共享范围指示信息用于指示所述待共享API的共享范围。
  7. 根据权利要求6所述的方法,其特征在于,所述第一CCF实体根据所述共享信息,确定所述目标CCF实体,包括:
    所述共享范围为所述第一CCF实体所属域内的CCF实体,所述第一CCF实体在所述第一CCF实体所属域内的CCF实体中确定所述目标CCF实体;或者,
    所述共享范围为所述第一CCF实体所属域外的CCF实体,所述第一CCF实体在所述第一CCF实体所属域外的CCF实体中确定所述目标CCF实体;或者,
    所述共享范围包括所述第一CCF实体所属域内的CCF实体,和所述第一CCF实体所属域外的CCF实体,所述第一CCF实体在所述第一CCF实体所属域内的CCF实体中确定第一目标CCF实体,并且在所述第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,所述目标CCF实体包括所述第一目标CCF实体和所述第二目标CCF实体。
  8. 根据权利要求7所述的方法,其特征在于,所述共享信息还包括目标域指示信息,所述目标域指示信息用于指示所述目标CCF实体所属的目标域;
    所述第一CCF实体在所述第一CCF实体所属域外的CCF实体中确定所述目标CCF实体,包括:
    所述第一CCF实体在所述目标域内的CCF实体中确定所述目标CCF实体。
  9. 根据权利要求7所述的方法,其特征在于,所述共享信息还包括目标域指示信息,所述目标域指示信息用于指示所述目标CCF实体所属的目标域;
    所述第一CCF实体在所述第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,包括:
    所述第一CCF实体在所述目标域内的CCF实体中确定所述第二目标CCF实体。
  10. 根据权利要求5所述的方法,其特征在于,所述第一CCF实体根据所述目标域指示信息确定第二目标CCF实体,包括:
    所述目标域指示信息为所述目标域的标识,所述第一CCF实体根据第二预设规则,在所述目标域内确定所述第二目标CCF实体;或者,
    所述目标域指示信息包括所述目标域的标识和域外目标CCF实体信息,所述第一CCF实体根据所述域外目标CCF实体信息,在所述目标域内确定所述第二目标CCF实体。
  11. 根据权利要求1所述的方法,其特征在于,所述第一CCF实体确定待共享API,包括:
    所述第一CCF实体根据第三预设规则,确定所述待共享API。
  12. 根据权利要求11所述的方法,其特征在于,所述方法还包括:
    所述第一CCF实体根据第四预设规则,确定所述目标CCF实体。
  13. 根据权利要求12所述的方法,其特征在于,所述目标CCF实体包括第一目标CCF实体,和/或第二目标CCF实体;
    其中,所述第一目标CCF实体所属域与所述第一CCF实体所属域相同;所述第二目标CCF实体所属域与所述第一CCF实体所属域不同。
  14. 根据权利要求5、10或13任一项所述的方法,其特征在于,所述第一CCF实体向所述待共享API的目标CCF实体共享所述待共享API的信息,包括:
    所述第一CCF实体向所述第二目标CCF实体共享所述待共享API的信息,所述待共享API的信息为全局信息。
  15. 根据权利要求14所述的方法,其特征在于,所述待共享API的信息包括所述待共享API的接口信息,所述接口信息为拓扑隐藏入口点的信息。
  16. 一种API发布方法,其特征在于,包括:
    应用程序接口API发布实体确定API的信息以及所述API的共享信息,所述共享信息用于指示第一通用应用程序接口核心CCF实体共享所述API;
    所述API发布实体向所述第一CCF实体发送第一API发布请求,所述第一API发布请求包括所述API的信息和所述API的共享信息。
  17. 根据权利要求16所述的方法,其特征在于,所述共享信息包括共享指示信息、目标CCF实体的信息或目标域指示信息中至少一个;
    其中,所述共享指示信息用于指示共享待共享API;所述目标域指示信息用于指示目 标域,所述目标域与所述第一CCF实体所属域不同。
  18. 根据权利要求16所述的方法,其特征在于,所述共享信息包括共享范围指示信息,所述共享范围指示信息用于指示待共享API的共享范围。
  19. 根据权利要求18所述的方法,其特征在于,所述共享信息还包括目标域指示信息,所述目标域指示信息用于指示所述目标CCF实体所属的目标域。
  20. 根据权利要求17所述的方法,其特征在于,
    所述目标域指示信息为所述目标域的标识;或者,
    所述目标域指示信息包括目标域的标识和域外目标CCF实体信息,所述域外目标CCF实体信息用于指示所述待共享API在所述目标域内的目标CCF实体信息。
  21. 一种通信装置,其特征在于,包括:
    处理模块,用于确定待共享应用程序接口API;
    发送模块,用于向所述待共享API的目标CCF实体共享所述待共享API的信息。
  22. 根据权利要求21所述的装置,其特征在于,所述装置还包括:接收模块,
    所述接收模块,用于接收第一API发布请求,所述第一API发布请求包括API的信息和所述API的共享信息;
    所述处理模块,具体用于根据所述第一API发布请求,确定所述待共享API。
  23. 根据权利要求22所述的装置,其特征在于,
    所述处理模块,还用于根据所述共享信息,确定所述目标CCF实体。
  24. 根据权利要求23所述的装置,其特征在于,所述共享信息包括共享指示信息、所述目标CCF实体的信息或目标域指示信息中至少一个;
    其中,所述共享指示信息用于指示共享所述待共享API;所述目标域指示信息用于指示目标域,所述目标域与第一CCF实体所属域不同。
  25. 根据权利要求24所述的装置,其特征在于,
    所述共享信息包括所述共享指示信息,所述处理模块,用于根据第一预设规则确定所述目标CCF实体;或者,
    所述共享信息包括所述目标CCF实体的信息,所述处理模块,用于根据所述目标CCF实体的信息确定所述目标CCF实体;或者,
    所述共享信息包括所述目标域指示信息,所述处理模块,用于根据所述目标域指示信息确定第二目标CCF实体,所述第二目标CCF实体为所述目标CCF实体中一个或多个,所述第二目标CCF实体所属域与所述第一CCF实体所属域不同。
  26. 根据权利要求23所述的装置,其特征在于,
    所述共享信息包括共享范围指示信息,所述共享范围指示信息用于指示所述待共享API的共享范围。
  27. 根据权利要求26所述的装置,其特征在于,
    所述共享范围为第一CCF实体所属域内的CCF实体,所述处理模块,用于在所述第一CCF实体所属域内的CCF实体中确定所述目标CCF实体;或者,
    所述共享范围为第一CCF实体所属域外的CCF实体,所述处理模块,用于在所述第一CCF实体所属域外的CCF实体中确定所述目标CCF实体;或者,
    所述共享范围包括第一CCF实体所属域内的CCF实体,和所述第一CCF实体所属域 外的CCF实体,所述处理模块,用于在所述第一CCF实体所属域内的CCF实体中确定第一目标CCF实体,并且在所述第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,所述目标CCF实体包括所述第一目标CCF实体和所述第二目标CCF实体。
  28. 根据权利要求27所述的装置,其特征在于,所述共享信息还包括目标域指示信息,所述目标域指示信息用于指示所述目标CCF实体所属的目标域;
    所述处理模块在所述第一CCF实体所属域外的CCF实体中确定所述目标CCF实体,具体包括:
    所述处理模块在所述目标域内的CCF实体中确定所述目标CCF实体。
  29. 根据权利要求27所述的装置,其特征在于,所述共享信息还包括目标域指示信息,所述目标域指示信息用于指示所述目标CCF实体所属的目标域;
    所述处理模块在所述第一CCF实体所属域外的CCF实体中确定第二目标CCF实体,具体包括:
    所述处理模块在所述目标域内的CCF实体中确定所述第二目标CCF实体。
  30. 根据权利要求25所述的装置,其特征在于,
    所述目标域指示信息为所述目标域的标识,所述处理模块,具体用于根据第二预设规则,在所述目标域内确定所述第二目标CCF实体;或者,
    所述目标域指示信息包括所述目标域的标识和域外目标CCF实体信息,所述处理模块,具体用于根据所述域外目标CCF实体信息,在所述目标域内确定所述第二目标CCF实体。
  31. 根据权利要求21所述的装置,其特征在于,所述处理模块具体用于:
    根据第三预设规则,确定所述待共享API。
  32. 根据权利要求31所述的装置,其特征在于,所述处理模块具体用于:
    根据第四预设规则,确定所述目标CCF实体。
  33. 根据权利要求32所述的装置,其特征在于,所述目标CCF实体包括第一目标CCF实体,和/或第二目标CCF实体;
    其中,所述第一目标CCF实体所属域与第一CCF实体所属域相同;所述第二目标CCF实体所属域与第一CCF实体所属域不同。
  34. 根据权利要求25、30或33任一项所述的装置,其特征在于,所述发送模块向所述待共享API的目标CCF实体共享所述待共享API的信息,具体包括:
    所述发送模块向所述第二目标CCF实体共享所述待共享API的信息,所述待共享API的信息为全局信息。
  35. 根据权利要求34所述的装置,其特征在于,所述待共享API的信息包括所述待共享API的接口信息,所述接口信息为拓扑隐藏入口点的信息。
  36. 一种通信装置,其特征在于,包括:
    处理模块,用于确定API的信息以及所述API的共享信息,所述共享信息用于指示第一通用应用程序接口核心CCF实体共享所述API;
    发送模块,用于向所述第一CCF实体发送第一API发布请求,所述第一API发布请求包括所述API的信息和所述API的共享信息。
  37. 根据权利要求36所述的装置,其特征在于,所述共享信息包括共享指示信息、 目标CCF实体的信息或目标域指示信息中至少一个;
    其中,所述共享指示信息用于指示共享待共享API;所述目标域指示信息用于指示目标域,所述目标域与所述第一CCF实体所属域不同。
  38. 根据权利要求36所述的装置,其特征在于,所述共享信息包括共享范围指示信息,所述共享范围指示信息用于指示待共享API的共享范围。
  39. 根据权利要求38所述的装置,其特征在于,所述共享信息还包括目标域指示信息,所述目标域指示信息用于指示所述目标CCF实体所属的目标域。
  40. 根据权利要求37所述的装置,其特征在于,
    所述目标域指示信息为所述目标域的标识;或者,
    所述目标域指示信息包括目标域的标识和域外目标CCF实体信息,所述域外目标CCF实体信息用于指示所述待共享API在所述目标域内的目标CCF实体信息。
  41. 一种计算机程序产品,包括:至少一个处理器,以及存储器;其特征在于,
    所述存储器用于存储计算机程序,使得所述计算机程序被所述至少一个处理器执行时实现如权利要求1-15任一项所述的API发布方法或者如权利要求16-20任一项所述的API发布方法。
  42. 一种计算机存储介质,其上存储有计算机程序,其特征在于,所述程序被处理器执行时实现如权利要求1-15任一项所述的API发布方法或者如权利要求16-20任一项所述的API发布方法。
PCT/CN2019/099041 2018-11-05 2019-08-02 一种api发布方法及装置 WO2020093742A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP19881835.3A EP3863312B1 (en) 2018-11-05 2019-08-02 Api publishing method and device
US17/308,414 US11533596B2 (en) 2018-11-05 2021-05-05 API publish method and apparatus

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN201811309187 2018-11-05
CN201811309187.8 2018-11-05
CN201910033213.7A CN111148076B (zh) 2018-11-05 2019-01-14 一种api发布方法及装置
CN201910033213.7 2019-01-14

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/308,414 Continuation US11533596B2 (en) 2018-11-05 2021-05-05 API publish method and apparatus

Publications (1)

Publication Number Publication Date
WO2020093742A1 true WO2020093742A1 (zh) 2020-05-14

Family

ID=70516629

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/099041 WO2020093742A1 (zh) 2018-11-05 2019-08-02 一种api发布方法及装置

Country Status (4)

Country Link
US (1) US11533596B2 (zh)
EP (1) EP3863312B1 (zh)
CN (1) CN111148076B (zh)
WO (1) WO2020093742A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022067736A1 (zh) * 2020-09-30 2022-04-07 华为技术有限公司 一种通信方法及装置

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108353093A (zh) * 2015-10-20 2018-07-31 中兴通讯股份有限公司 使用网络接口公开服务

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6511520B2 (ja) * 2014-10-28 2019-05-15 コンヴィーダ ワイヤレス, エルエルシー 下層ネットワークとのサービス層課金相関の方法および装置
EP3281168A4 (en) * 2015-07-31 2018-03-14 Hewlett-Packard Enterprise Development LP Discovering and publishing api information
EP3264727B1 (en) * 2016-07-01 2024-05-08 Nokia Solutions and Networks Oy Database, network entity and method for the support of user location change reporting
US10942794B2 (en) * 2017-05-02 2021-03-09 Samsung Electronics Co.. Ltd. Method and apparatus for providing network-based northbound application programming interface in a wireless communication system
WO2019194665A1 (en) * 2018-04-06 2019-10-10 Samsung Electronics Co., Ltd. Method and device for performing onboarding

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108353093A (zh) * 2015-10-20 2018-07-31 中兴通讯股份有限公司 使用网络接口公开服务

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
HUAWEI ET AL.: "API publish and API discover for CAPIF interconnection", 3GPP DRAFT; 23222_CR0035R2, 19 October 2018 (2018-10-19), Vilnius, Lithuana, pages 1 - 4, XP051477933 *
HUAWEI ET AL: "API sharing for CCF interconnection", 3GPP DRAFT; S6-190175, 25 January 2019 (2019-01-25), Kochi, India, pages 1 - 4, XP051612366 *
See also references of EP3863312A4

Also Published As

Publication number Publication date
EP3863312B1 (en) 2023-04-26
CN111148076B (zh) 2023-03-24
EP3863312A4 (en) 2021-10-13
US20210258753A1 (en) 2021-08-19
EP3863312A1 (en) 2021-08-11
US11533596B2 (en) 2022-12-20
CN111148076A (zh) 2020-05-12

Similar Documents

Publication Publication Date Title
US20210218585A1 (en) Local area network communication method, device, and system
JP6821061B2 (ja) ポリシー制御方法、ネットワーク要素、およびシステム
EP3592012B1 (en) Subscription update method, device and system
JP7027558B2 (ja) 認可取り消しの方法および装置
US11778455B2 (en) Subscriber identity management method, device, and system
US11646939B2 (en) Network function NF management method and NF management device
US10897699B2 (en) Subscription update method, device, and system
WO2021088882A1 (zh) 数据共享的方法、设备及系统
WO2020228751A1 (zh) 一种通信方法和装置
US20220417366A1 (en) Charging method and apparatus
WO2020253344A1 (zh) 一种授权控制的方法、装置以及存储介质
US11726848B2 (en) API topology hiding method, device, and system
US20230359515A1 (en) Method and Apparatus for Application Programming Interface Management
WO2020093742A1 (zh) 一种api发布方法及装置
WO2021115447A1 (zh) 会话管理网元发现的方法、设备及系统
WO2021163974A1 (zh) 一种通信方法及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19881835

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2019881835

Country of ref document: EP

Effective date: 20210505