我正在通过API从外部系统(Salesforce Marketing Cloud)获取一些数据,然后以以下格式返回数据:
Results: [(List){
Client =
(ClientID){
ID = 113903
}
PartnerKey = None
CreatedDate = 2013-07-29 04:43:32.000073
ModifiedDate = 2013-07-29 04:43:32.000073
ID = 1966872
ObjectID = None
CustomerKey = "343431CD-031D-43C7-981F-51B778A5A47F"
ListName = "PythonSDKList"
Category = 578615
Type = "Private"
Description = "This list was created with the PythonSDK"
ListClassification = "ExactTargetList"
}]
这个格式与 JSON 十分接近,我想把它格式化成 JSON 文件以便导入到我们的数据库中。有什么好的方法吗?
谢谢。
pyparsing
包。 - alecxe