Updating Mapper

The update_mapper() method in Cataloglake allows users to update metadata mappings associated with specific accounts in the catalog. This operation helps in aligning and modifying metadata attributes dynamically for better data handling and consistency.

Payload Example

update_mapper_payload={
    "groc_account_id": "c4ca4238a0b923820dcc509a6f75849b",
    "metadata_mapper_id": "36769c86-c320-4539-a073-f9f9319977f6",
    "metadata_keymap": [
        {
            "address of manufacturer": "manufacturer_address",
            "fssai number": "fssai_number",
            "marketing_fssai_num": "marketing_fssai_number",
            "fabric_colour": "colour",
            "new_map": "fssai_number",
            "new_address of manufacturer": "fssai_number"
        }
    ]
}

Usage example

update_mapper = cataloglake.update_mapper(upadate_mapper_payoad)
print(update_mapper)

Example Response

{
  "message": "Mapping updated successfully.",
  "mapping": {
    "metadata_mapper_id": "36769c86-c320-4539-a073-f9f9319977f6",
    "mapper_name": "",
    "metadata_keymap": [
      {
        "address of manufacturer": "manufacturer_address",
        "fssai number": "None",
        "marketing_fssai_num": "marketing_fssai_number",
        "fabric_colour": "colour",
        "new_map": "None",
        "new_address of manufacturer": "fssai_number"
      }
    ]
  }
}

Last updated