A static aggregation code scenario multiplexing method

By providing multiple template application configurations through the aggregated code system, the problem of QR code re-creation during the functional upgrade of QR code application scenarios is solved, realizing the horizontal expansion of business capabilities and the scalability of the system.

CN116108867BActive Publication Date: 2026-07-07GOGBUY COM

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
GOGBUY COM
Filing Date
2023-02-01
Publication Date
2026-07-07

AI Technical Summary

Technical Problem

In existing technologies, QR code applications are often specific to certain scenarios, which means that a large number of static QR code signs need to be remade when upgrading functions, making it impossible to achieve horizontal expansion of business capabilities.

Method used

The aggregation code system provides multiple template application configurations. After scanning the code using a scanning device that integrates the aggregation code SDK, the scenario code is transmitted. The aggregation code CLI system identifies the business system and scenario to obtain the appropriate template application configuration, parses and obtains the aggregation code source data, and initiates the business execution process according to the configured execution type.

Benefits of technology

It enables horizontal expansion of business capabilities without redrawing offline QR codes, enhancing the system's scalability and facilitating business system integration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116108867B_ABST
    Figure CN116108867B_ABST
Patent Text Reader

Abstract

The application discloses a static aggregation code scene reuse method, a plurality of sets of template application configurations can be configured through an aggregation code, scene coding is transmitted after a code scanning device integrated with an aggregation code SDK scans a code, a business system and a scene are recognized by an aggregation code cli system, and template application configurations adapted to the scene are acquired. After the corresponding template application configurations are read, aggregation code source data is acquired by analysis, and a business execution process is initiated according to the execution type configured. The requested link and parameters can be subjected to rule checking, and the matching of the voucher capability and the scene. A standardized execution process is provided by a unified integrated SDK package, a new business system only needs to be simply integrated and developed to be seamlessly connected into the whole system ecology, the expansibility of the system is enhanced, and meanwhile, the standardized interface integrated mode greatly facilitates the integration of external third-party systems.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of QR code application technology, specifically to a method for reusing static aggregated codes in various scenarios. Background Technology

[0002] Two-dimensional codes, also known as two-dimensional barcodes, are commonly referred to as QR codes. QR stands for Quick Response, and it's an encoding method that has become extremely popular on mobile devices in recent years, capable of representing various data types. Two-dimensional barcodes / QR codes are black-and-white graphics distributed in a two-dimensional plane using specific geometric patterns. They cleverly utilize the concept of "0" and "1" bit streams, the foundation of computer logic, using several geometric shapes corresponding to binary to represent textual and numerical information. This information is automatically processed by image input devices or photoelectric scanning devices. It shares some common characteristics with barcode technology: each code system has its specific character set; each character occupies a certain width; and it has certain verification functions. It also has the ability to automatically identify information in different rows and handle graphic rotation changes. Based on the assimilation of relevant foreign technical data, my country has formulated two national standards for QR codes: QR code grid matrix code (SJ / T 11349-2006) and QR code compact matrix code (SJ / T11350-2006).

[0003] In the internet age, users install QR code scanning clients on their mobile devices, use their phones to photograph and recognize QR code images printed in media, newspapers, etc., obtain the content stored in the QR code, and trigger related applications to provide users with various information services. These QR code-based applications are often specific to certain scenarios; for example, payment QR codes can only complete payment functions, and traceability QR codes can only query product traceability information. This often requires the production of a large number of QR code signs for different users. When an application upgrades its functionality, it may face the problem of updating and re-creating the static QR code signs or aggregated QR codes already deployed and distributed in the market. Summary of the Invention

[0004] This invention provides a static aggregation code scenario reuse method. A single aggregation code can correspond to multiple sets of template application configurations. After scanning the code using a scanning device with an integrated aggregation code SDK, the scenario code is transmitted. The aggregation code CLI system identifies the business system and scenario to obtain the template application configuration adapted to the scenario. The corresponding template application configuration is read, the aggregation code source data is parsed and obtained, and the business execution process is initiated according to the configured execution type. When the business system's functions are expanded, there is no need to redraw and deploy offline QR codes, thus achieving horizontal expansion of business capabilities.

[0005] The specific technical solution is as follows:

[0006] A static aggregated code scenario reuse method includes three types of service instance implementations: a scanning client, an aggregated code service, and an application system that provides business scenario functions.

[0007] 1. QR code scanning client: Mobile applications with scanning capabilities;

[0008] 2. Aggregated Code Service: The aggregated code system provides capabilities such as aggregated code data rule setting, aggregated code generation, and scenario configuration. The aggregated code system includes 5 functional modules:

[0009] 1) Gateway: As the unified entry point of the system, the gateway is responsible for backend service integration, dynamic scaling, load balancing, circuit breaking, and other functions.

[0010] 2) Server: The core service handles data storage and encoding rules;

[0011] 3) API: An interface layer service that provides business systems with the ability to set up and generate aggregate codes;

[0012] 4) CLI: Aggregator code processing service for client scanning requests;

[0013] 5) media: Multimedia service, used to generate aggregated QR code images and upload them to object storage service;

[0014] 3. Application systems that provide business scenario functions: After the aggregation code service identifies the scenario, it calls the service to implement the specific business function; the application system registers the application, configures the scenario and execution capabilities in the aggregation code system;

[0015] The aggregation code service defines aggregation code data rules, including data template definition. Its data format is: platform identifier: business identifier@{business parameter}. The @ symbol is used as a data separator. The content before the @ symbol is defined by the aggregation code system and can be expanded. The content after the @ symbol is the data package set by the business system.

[0016] The data packet content set by the application system is declared using JSON object format. Multiple parameter pairs are concatenated in key:value format, and the value placeholder is declared as ${param}. ${} is used as parameter placeholders to fill parameter values ​​according to parameter names when generating aggregate code source data.

[0017] The specific implementation steps of aggregated code reuse are as follows:

[0018] 1. The application system registers its application in the aggregation code system;

[0019] 2. Create an aggregated code data template in the aggregated code system;

[0020] 3. Create a snapshot of the aggregated code data template and calculate the information digest of the template rules;

[0021] 4. Application system configuration for creating a data template: Select an existing data template, select the application system used by the aggregation code system, and configure the scenario code, the type of action to be executed, and the default callback URL information;

[0022] 5. Generate aggregated source code data;

[0023] 6. The application system configures the application settings for the data template based on the configured data template and business scenario;

[0024] 7. The application system calls the aggregation code system interface to generate aggregation code;

[0025] 8. The application system passes in the placeholder parameters for ${param} according to the data template convention;

[0026] 9. The aggregation code system replaces the placeholder parameter ${param} in the data template content to generate aggregation code source data;

[0027] 10. Generate short codes from encrypted source data:

[0028] (1) Calculate the MD5 value of the source data content and check if there is a record with the same value in the short code mapping table;

[0029] (2) Obtain a snowflake ID from the ID service, calculate its base-62 characters, and generate a random ID;

[0030] (3) Perform a bitwise AND operation between the source content summary data and 0x3FFFFFFF in 8-bit hexadecimal groups, perform a bitwise AND operation between the obtained value and 0x0000003D, obtain the character array chars index, add the obtained characters, shift right by 5 bits in each loop, and store the string into the output array at the corresponding index, resulting in 4 groups of 6-bit strings;

[0031] (4) Generate random numbers below 4 and use them as array indexes to extract the string at the corresponding position from the array as short chain characters;

[0032] (5) Concatenate the short code characters with a random ID, and then add a random factor to generate an obfuscated string. This obfuscated string is used to generate the aggregate code.

[0033] (6) If all elements in the array have duplicate characters, then regenerate the short code;

[0034] 11. Generate aggregated code identification data according to the data format {platform identifier}:{short code}:{random ID};

[0035] 12. Use the transposition obfuscation method to generate aggregate code encoding;

[0036] 13. Concatenate the aggregation code gateway address to generate the aggregation code access link;

[0037] 14. Integrate the zxing package to draw the aggregate code access link as a QR code image and upload it to the object storage service for public access;

[0038] 15. When a user scans a QR code using a mobile client that integrates the aggregation code SDK, a request is made to access the aggregation code link. The client request carries the client identifier, scenario identifier, or allowed custom parameter state.

[0039] 16. The Aggregator Code CLI service receives the Aggregator Code encoding, reverse-processes the characters of the Aggregator Code encoding using an obfuscation method, and obtains the short code.

[0040] 17. The Aggregator Code CLI system uses short codes to query short code source data;

[0041] 18. Determine whether the aggregation code is allowed to be accessed based on the query records; the criteria for allowing access include whether the validity period of the aggregation code, the application identifier, and the scenario identifier match.

[0042] 19. Response: The aggregate code cannot be accessed validly; the aggregate code has expired.

[0043] 20. The aggregate code can be accessed effectively, and the template configured in this application scenario can be queried. The function is implemented based on the execution action type of the aggregate code template.

[0044] 21. If the action type is selected as redirection or routing, the page address to which the response will redirect;

[0045] 22. If the action type is selected as "execution call", the service interface address configured will be called to respond to the business system with the service call result;

[0046] 23. Response to "Aggregate code template expired": The aggregate code has expired.

[0047] The application system executes three types of actions in the aggregate code system:

[0048] 1) redirect: redirects to the configured address with parameters;

[0049] 2) route: The response includes the frontend route address along with the QR code parameters;

[0050] 3) execute: Sends a request to the business system address with the scan parameters and receives the response result;

[0051] Implementation of aggregated code reuse:

[0052] One aggregation code corresponds to multiple sets of data template application configurations. After the client scans the code, it transmits the scene code, and the aggregation code CLI system identifies the business system and scene to obtain the template application configuration adapted to that scene.

[0053] The corresponding data template application configuration is read, the aggregated source code data is parsed and obtained, and the business execution process is initiated according to the configured execution type.

[0054] The platform identifier data portion of the aggregated code source data can be dynamically replaced by the scanning application according to the scenario conditions when scanning the code, while the data packet portion of the business system is determined when the data template is generated.

[0055] The beneficial effects of this invention are:

[0056] 1. When using a scanning device application with an integrated aggregate code SDK to complete the scanning operation, the application can perform rule validation on the requested link and parameters, match coupon capabilities and scenarios, and make the scanning access process controllable.

[0057] 2. In real-world scenarios, a large number of static QR codes often need to be deployed. When the application system expands its functions, there is no need to redraw and deploy offline QR codes, thus achieving horizontal expansion of business capabilities.

[0058] 3. The unified integration SDK package provides a standardized execution process. New business systems can be seamlessly integrated into the entire system ecosystem with simple integration development, which enhances the scalability of the system. At the same time, the standardized interface integration method greatly facilitates the integration of services from external third-party systems, allowing the development teams of business systems to focus more on the implementation of business functions in specific scenarios. Attached image description:

[0059] Figure 1 This is a network diagram illustrating the implementation of aggregated code multiplexing in this invention.

[0060] Figure 2 This is an execution timing diagram of a barcode scanning scenario using a barcode scanning device with an integrated aggregate code SDK in this invention;

[0061] Figure 3 This is an execution timing diagram for a typical browser scanning scenario in this invention;

[0062] Figure 4 This is a flowchart of the aggregation code generation process in this invention;

[0063] Figure 5 This is a flowchart of the aggregation code parsing and execution process in this invention. Detailed implementation method:

[0064] A static aggregated code scenario reuse method includes three types of service instance implementations: a scanning client, an aggregated code service, and a business application system that provides business scenario functions.

[0065] 1. QR code scanning client: Mobile applications with scanning capabilities;

[0066] 2. Aggregated Code Service: The aggregated code system provides capabilities such as aggregated code data rule setting, aggregated code generation, and scenario configuration. The aggregated code system includes 5 functional modules:

[0067] 1) Gateway: As the unified entry point of the system, the gateway is responsible for backend service integration, dynamic scaling, load balancing, circuit breaking, and other functions.

[0068] 2) Server: The core service handles data storage and encoding rules;

[0069] 3) API: An interface layer service that provides business systems with the ability to set up and generate aggregate codes;

[0070] 4) CLI: Aggregator code processing service for client scanning requests;

[0071] 5) media: Multimedia service, used to generate aggregated QR code images and upload them to object storage service;

[0072] 3. Application systems that provide business scenario functions: After the aggregation code service identifies the scenario, it calls the service to implement the specific business function; the application system registers the application, configures the scenario and execution capabilities in the aggregation code system;

[0073] The aggregation code service defines aggregation code data rules, including data template definition. Its data format is: platform identifier: business identifier@{business parameter}. The @ symbol is used as a data separator. The content before the @ symbol is defined by the aggregation code system and can be expanded. The content after the @ symbol is the data package set by the business system.

[0074] The data packet content set by the application system is declared using JSON object format. Multiple parameter pairs are concatenated in key:value format, and the value placeholder is declared as ${param}. ${} is used as parameter placeholders to fill parameter values ​​according to parameter names when generating aggregate code source data.

[0075] The specific implementation steps of aggregated code reuse are as follows:

[0076] 1. The application system registers its application in the aggregation code system;

[0077] 2. Create an aggregated code data template in the aggregated code system;

[0078] 3. Create a snapshot of the aggregated code data template and calculate the information digest of the template rules;

[0079] 4. Application system configuration for creating a data template: Select an existing data template, select the application system used by the aggregation code system, and configure the scenario code, the type of action to be executed, and the default callback URL information;

[0080] 5. Generate aggregated source code data;

[0081] 6. The application system configures the application settings for the data template based on the configured data template and business scenario;

[0082] 7. The application system calls the aggregation code system interface to generate aggregation code;

[0083] 8. The application system passes in the placeholder parameters for ${param} according to the data template convention;

[0084] 9. The aggregation code system replaces the placeholder parameter ${param} in the data template content to generate aggregation code source data;

[0085] 10. Generate short codes from encrypted source data:

[0086] (7) Calculate the MD5 value of the source data content and check if there is a record with the same value in the short code mapping table;

[0087] (8) Obtain a snowflake ID from the ID service, calculate its base-62 characters, and generate a random ID;

[0088] (9) Perform a bitwise AND operation between the source content summary data and 0x3FFFFFFF in 8-bit hexadecimal groups, perform a bitwise AND operation between the obtained value and 0x0000003D, obtain the character array chars index, add the obtained characters, shift right by 5 bits in each loop, and store the string into the output array at the corresponding index, resulting in 4 groups of 6-bit strings;

[0089] (10) Generate random numbers below 4 and use them as array indexes to extract the string at the corresponding position from the array as short chain characters;

[0090] (11) Short code characters are concatenated with a random ID, and then a random factor is added to generate an obfuscated string, which is used to generate the aggregate code;

[0091] (12) If all elements in the array have duplicate characters, then regenerate the short code;

[0092] 11. Generate aggregated code identification data according to the data format {platform identifier}:{short code}:{random ID};

[0093] 12. Use the transposition obfuscation method to generate aggregate code encoding;

[0094] 13. Concatenate the aggregation code gateway address to generate the aggregation code access link;

[0095] 14. Integrate the zxing package to draw the aggregate code access link as a QR code image and upload it to the object storage service for public access;

[0096] 15. When a user scans a QR code using a mobile client that integrates the aggregation code SDK, a request is made to access the aggregation code link. The client request carries the client identifier, scenario identifier, or allowed custom parameter state.

[0097] 16. The Aggregator Code CLI service receives the Aggregator Code encoding, reverse-processes the characters of the Aggregator Code encoding using an obfuscation method, and obtains the short code.

[0098] 17. The Aggregator Code CLI system uses short codes to query short code source data;

[0099] 18. Determine whether the aggregation code is allowed to be accessed based on the query records; the criteria for allowing access include whether the validity period of the aggregation code, the application identifier, and the scenario identifier match.

[0100] 19. Response: The aggregate code cannot be accessed validly; the aggregate code has expired.

[0101] 20. The aggregate code can be accessed effectively, and the template configured in this application scenario can be queried. The function is implemented based on the execution action type of the aggregate code template.

[0102] 21. If the action type is selected as redirection or routing, the page address to which the response will redirect;

[0103] 22. If the action type is selected as "execution call", the service interface address configured will be called to respond to the business system with the service call result;

[0104] 23. Response to "Aggregate code template expired": The aggregate code has expired.

[0105] 24. When a user scans a QR code using other scanning applications (without integrating the aggregate code SDK, such as a regular browser), a request for access to the aggregate code link is initiated. This request will not carry the client identifier, scene identifier, or allowed custom parameter state.

[0106] 25. The aggregation code CLI execution steps

[16] -

[22] are as follows, where the aggregation code template read in the steps is not the default implementation of the system's default configuration. Non-business system customized business processing flow.

[0107] 26. An aggregated code can be accessed by different scanning devices and can be used to implement different business functions.

[0108] The application system executes three types of actions in the aggregate code system:

[0109] 1) redirect: redirects to the configured address with parameters;

[0110] 2) route: The response includes the frontend route address along with the QR code parameters;

[0111] 3) execute: Sends a request to the business system address with the scan parameters and receives the response result;

[0112] Implementation of aggregated code reuse:

[0113] One aggregation code corresponds to multiple sets of data template application configurations. After the client scans the code, it transmits the scene code, and the aggregation code CLI system identifies the business system and scene to obtain the template application configuration adapted to that scene.

[0114] The corresponding data template application configuration is read, the aggregated source code data is parsed and obtained, and the business execution process is initiated according to the configured execution type.

[0115] Among them, the platform identification data part of the aggregated code source data can be dynamically replaced by the scanning application according to the scenario conditions when scanning the code, and the business system data packet part is determined when the data template is generated.

Claims

1. A method for reusing static aggregated code scenarios, characterized in that, It is implemented through three types of service instances: QR code scanning client, aggregated code service, and application system that provides business scenario functions; A. QR code scanning client: Mobile applications with scanning capabilities; B. Aggregated Code Service: Through the aggregated code system, it provides capabilities for defining aggregated code data rules, generating aggregated codes, and configuring scenarios. The aggregated code system includes 5 functional modules: 1) Gateway: As the unified entry point of the system, the gateway is responsible for backend service integration, dynamic scaling, load balancing, and circuit breaking; 2) Server: The core service handles data storage and encoding rules; 3) API: An interface layer service that provides business systems with the ability to set up and generate aggregate codes; 4) CLI: Aggregator code processing service for client scanning requests; 5) media: Multimedia service, used to generate aggregated QR code images and upload them to object storage services; C. Business systems that provide business scenario functions: After the aggregation code service identifies the scenario, it calls the service to implement the specific business function; the business system registers the application, configures the scenario, and executes the capability in the aggregation code system; The aggregation code service defines aggregation code data rules, including data template definition. Its data format is: platform identifier: business identifier@{business parameter}. The @ symbol is used as a data separator. The content before the @ symbol is defined by the aggregation code system and can be expanded. The content after the @ symbol is the data package set by the business system. The data packet content set by the application system is declared using JSON object format. Multiple parameter pairs are concatenated in key:value format, and the value placeholder is declared as ${param}. ${} is used as parameter placeholders to fill parameter values ​​according to parameter names when generating aggregate code source data. The specific implementation steps of aggregated code reuse are as follows: 1) The application system is registered and used in the aggregation code system; 2) Create an aggregated code data template in the aggregated code system; 3) Create a snapshot of the aggregated code data template and calculate the information digest of the template rules; 4) Create application system configuration for the data template: Select an existing data template, select the application system used by the aggregation code system, and configure the scenario code, the type of action to be executed, and the default callback URL information; 5) Generate aggregated source code data; 6) The application system configures the application settings for the data template based on the configured data template and business scenario; 7) The application system calls the aggregation code system interface to generate aggregation code; 8) The application system passes in the placeholder parameters for ${param} according to the data template convention; 9) The aggregation code system replaces the placeholder parameter ${param} in the data template content to generate aggregation code source data; 10) Generate short codes from encrypted source data: 11) Generate aggregated code identification data according to the data format {platform identifier}:{short code}:{random ID}; 12) Generate aggregate code encoding using the transposition obfuscation method; 13) Concatenate the aggregation code gateway address to generate the aggregation code access link; 14) Integrate the zxing package to draw the aggregate code access link as a QR code image and upload it to the object storage service for public access; 15) When a user scans a QR code using a mobile client that integrates the aggregation code SDK, a request is made to access the aggregation code link. The client request carries the client identifier, scenario identifier, or allowed custom parameter state. 16) The Aggregator Code CLI service receives the Aggregator Code encoding, reverse-processes the characters of the Aggregator Code encoding using an obfuscation method, and obtains the short code; 17) The Aggregator Code CLI system uses short codes to query short code source data; 18) Determine whether the aggregation code is allowed to be accessed based on the query records; the criteria for allowing access include whether the validity period of the aggregation code, the application identifier, and the scenario identifier match. 19) Response: The aggregate code cannot be accessed validly; the aggregate code has expired. 20) The aggregate code can be accessed effectively, and the template configured in this application scenario can be queried. The function is implemented based on the execution action type of the aggregate code template. 21) If the action type is selected as redirection or routing, the page address to which the response will redirect; 22) The action type is selected as "execute call", which calls the configured service interface address to respond to the business system service call result; 23) Response to "Aggregate code template invalid" - "Aggregate code has expired"; 24) Implementation of aggregated code reuse: One aggregation code corresponds to multiple sets of data template application configurations. After the client scans the code, it transmits the scene code, and the aggregation code CLI system identifies the business system and scene to obtain the template application configuration adapted to that scene. The corresponding data template application configuration is read, the aggregated source code data is parsed and obtained, and the business execution process is initiated according to the configured execution type.

2. The static aggregation code scenario reuse method according to claim 1, characterized in that, The application system executes three types of actions in the aggregate code system: 1) redirect: redirects to the configured address with parameters; 2) route: The response includes the frontend route address along with the QR code parameters; 3) execute: Sends a request to the business system address with the scan parameters and receives the response result.

3. The static aggregation code scenario reuse method according to claim 1, characterized in that, The platform data portion of the aggregated source code data can be dynamically replaced by the scanning application based on the scenario conditions when scanning, while the data packet portion of the business system is determined when the data template is generated.

4. The static aggregation code scenario reuse method according to claim 1, characterized in that, The steps for generating short codes from the encrypted source data include: 1) Calculate the MD5 value of the source data content and check if there is a matching record in the short code mapping table; 2) Obtain a snowflake ID from the ID service, calculate its hexadecimal characters, and generate a random ID; 3) Perform a bitwise AND operation between the source content summary data and 0x3FFFFFFF in 8-bit hexadecimal groups. Perform a bitwise AND operation between the resulting value and 0x0000003D to obtain the character array index chars. Add the obtained characters together. In each loop, shift the right by 5 bits and store the string in the output array at the corresponding index, resulting in 4 groups of 6-bit strings. 4) Generate random numbers below 4 and use them as array indexes to extract the corresponding string from the array as short chain characters; 5) Concatenate the short code characters with a random ID, then add a random factor to generate an obfuscation string, which is used to generate the aggregate code; 6) If all elements in the array have duplicate characters, then regenerate the short code.