You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am currently trying to test whether more arguments can be added to the already built payloads, for example, adding transaction_id in RequestStartTransactionPayload. Part of the reason I am trying to add this is because other available implementations of ocpp2.0.1 do include these fields. My initial attempts include adding the transaction_id in the class definition of the payload as follows:
At first glance, I believe the custom_data field is what you need. Please look up OCPP-2.0.1_edition3_part4_ocpp-j-specification: Section 9: CustomData Extension for more details.
Hi,
I am currently trying to test whether more arguments can be added to the already built payloads, for example, adding transaction_id in RequestStartTransactionPayload. Part of the reason I am trying to add this is because other available implementations of ocpp2.0.1 do include these fields. My initial attempts include adding the transaction_id in the class definition of the payload as follows:
@DataClass
class RequestStartTransactionPayload:
id_token: Dict
remote_start_id: int
evse_id: Optional[int] = None
group_id_token: Optional[Dict] = None
charging_profile: Optional[Dict] = None
custom_data: Optional[Dict[str, Any]] = None
transaction_id: str
I have bolded what I added into the class definition. However, when I try to run this, it gives me the following error:
request = call.RequestStartTransactionPayload(
TypeError: RequestStartTransactionPayload.init() got an unexpected keyword argument 'transaction_id'
What other files should be edited in order to make the test successful?
The text was updated successfully, but these errors were encountered: