Skip to content

Send consumption information serialization is missing deliveryStatus field. #388

@ohadbenita

Description

@ohadbenita

The send_consumption_information method fails to serializae the deliveryStatus field, for example:

api_client.send_consumption_information(
    transaction_id="some-transaction-id",
    consumption_request=ConsumptionRequest(
        customerConsented=True,
        sampleContentProvided=True,
        deliveryStatus=DeliveryStatus.DELIVERED,
        consumptionPercentage=0,
        refundPreference=RefundPreference.DECLINE,
    )
)

results in JSON:

{'consumptionPercentage': 0, 'customerConsented': True, 'refundPreference': 'DECLINE', 'sampleContentProvided': True}

See line 681 in api_client.py.
This should be fixed ASAP as this breaks this method's functionality completely.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions