Sapo Trường Tùy Chỉnh icon

Sapo Trường Tùy Chỉnh

Quản lý trường tùy chỉnh trên Sapo

Khách Hàng → Xóa

AI-generated

Overview

This node manages custom metafields on various resources within the Sapo platform, such as customers, products, orders, and more. Specifically for the "Khách Hàng" (Customer) resource with the "Xóa" (Delete) operation, it deletes a specified custom metafield associated with a customer.

Common scenarios where this node is useful include:

  • Removing obsolete or incorrect custom data fields from customer records.
  • Cleaning up metadata after customer data updates or migrations.
  • Automating maintenance tasks to keep customer metadata relevant and accurate.

For example, if you have a custom metafield storing a loyalty program ID for customers and that program ends, you can use this node to delete that metafield from all affected customers.

Properties

Name Meaning
ID Tài Nguyên The unique numeric identifier of the customer resource from which the metafield will be deleted.
ID Trường Tùy Chỉnh The unique numeric identifier of the custom metafield to delete from the specified customer.

Output

The output JSON contains a single field indicating success:

{
  "success": true
}

This confirms that the metafield was successfully deleted from the customer resource.

No binary data is output by this operation.

Dependencies

  • Requires an active connection to the Sapo API via an API key credential configured in n8n.
  • The node depends on the internal SapoApiBase class to interact with the Sapo metafields API endpoints.
  • Proper permissions on the Sapo account are necessary to delete metafields on customer resources.

Troubleshooting

  • Common issues:

    • Providing an invalid or non-existent customer ID or metafield ID will cause errors.
    • Insufficient API permissions may result in authorization errors.
    • Network connectivity problems can prevent successful API calls.
  • Error messages:

    • Errors returned from the Sapo API will be surfaced with their message. For example, "Metafield not found" indicates the metafield ID does not exist for the given customer.
    • Authentication errors suggest checking the API key credentials.
  • Resolution tips:

    • Verify that the customer ID and metafield ID are correct and exist in your Sapo store.
    • Ensure the API key has the required scopes/permissions.
    • Check network connectivity and retry if transient errors occur.

Links and References

Discussion