{"behavior":"degenerate_repetition","label_filter":null,"limit":10,"next_offset":30469,"offset":30459,"previous_offset":null,"rows":[{"assistant_initiates":false,"asst_text":"0","behavior":"degenerate_repetition","conversation_hash":"09d6ee222878a4da05b8d5e4aaf3e52b","conversation_redacted":false,"conversation_toxic":false,"country":"","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"Russian","model":"gpt-4o-2024-08-06","n_chars":836,"n_turns_in_conversation":1,"n_words":107,"source_row_offset":30459,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:24 GMT","turn_id":"1633400a01287ac61b504450","turn_index":0,"user_text":"\n        \u0427\u0435\u043b\u043e\u0432\u0435\u043a \u043f\u043e\u0442\u0435\u0440\u044f\u043b \u0441\u0432\u0435\u0433\u043e \u043b\u044e\u0431\u0438\u043c\u043e\u0433\u043e \u043f\u0438\u0442\u043e\u043c\u0446\u0430 \u0438 \u043d\u0430\u043f\u0438\u0441\u0430\u043b \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0438\u0442\u043e\u043c\u0446\u0430.\n        \u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0438\u0442\u043e\u043c\u0446\u0430 \u043c\u043e\u0436\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043c\u0435\u0441\u0442\u043e \u043f\u043e\u0442\u0435\u0440\u0438, \u0446\u0432\u0435\u0442 \u043e\u0448\u0435\u0439\u043d\u0438\u043a\u0430 \u0438 \u0442.\u0434.\n        \u0422\u0430\u043a\u0436\u0435 \u0435\u0441\u0442\u044c \u043f\u043e\u0441\u0442 \u0441 \u0412\u041a \u043e \u043f\u043e\u0442\u0435\u0440\u044f\u043d\u043e\u043c \u0436\u0438\u0432\u043e\u0442\u043d\u043e\u043c.\n        \u0422\u0435\u0431\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043e\u0446\u0435\u043d\u0438\u0442\u044c \u0447\u0438\u0441\u043b\u043e\u043c \u043e\u0442 0 \u0434\u043e 10 \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0438\u0442\u043e\u043c\u0446\u0430 \u0432 \u043f\u043e\u0441\u0442\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044e \u0447\u0435\u043b\u043e\u0432\u0435\u043a\u0430.\n        0 - \u043f\u043e\u043b\u043d\u0430\u0441\u0442\u044c\u044e \u043d\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0443\u0435\u0442\n        10 - \u043f\u043e\u043b\u043d\u0430\u0441\u0442\u044c\u044e \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0443\u0435\u0442\n        \u0422\u042b \u0423\u041c\u0415\u0415\u0428\u042c \u042d\u0422\u041e \u0414\u0415\u041b\u0410\u0422\u042c!\n        \u041e\u0422\u0412\u0415\u0427\u0410\u0419 \u0422\u041e\u041b\u042c\u041a\u041e \u0427\u0418\u0421\u041b\u041e \u041e\u0422 0 \u0414\u041e 10 \u0411\u0415\u0417 \u041a\u0410\u041a\u041e\u0413\u041e \u041b\u0418\u0411\u041e \u0422\u0415\u041a\u0421\u0422\u0410!\n\n        \u0422\u0435\u043a\u0441\u0442 \u0432\u043b\u0430\u0434\u0435\u043b\u044c\u0446\u0430 \u043f\u0438\u0442\u043e\u043c\u0446\u0430\n        \"\n        \u0412 \u0412\u043e\u0440\u043e\u043d\u0435\u0436\u0435 \u043f\u043e\u0442\u0435\u0440\u044f\u043b\u0430\u0441\u044c \u0441\u043e\u0431\u0430\u0447\u043a\u0430 \u0441 \u043e\u0448\u0435\u0439\u043d\u0438\u043a\u043e\u043c\n        \"\n        \u0422\u0435\u043a\u0441\u0442 \u043f\u043e\u0441\u0442\u0430\n        \"\n        https://vk.com/polina_skl\n\u0425\u0438\u043c\u043a\u0438 \u041d\u0430\u0439\u0434\u0435\u043d\u0430 \u043d\u0435\u043c\u0435\u0446\u043a\u0430\u044f \u043e\u0432\u0447\u0430\u0440\u043a\u0430, \u0434\u0435\u0432\u043e\u0447\u043a\u0430. \u0412\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u043d\u0435\u0434\u0430\u0432\u043d\u043e \u0440\u043e\u0434\u0438\u043b\u0430. \u0412\u0438\u0441\u044f\u0442 \u0441\u043e\u0441\u043a\u0438. \u0427\u0438\u043f \u0438 \u043a\u043b\u0435\u0439\u043c\u043e \u043d\u0435 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u044b\n\nhttps://vk.com/sunau\n\u041d\u0430\u0439\u0434\u0435\u043d\u0430 \u043e\u0432\u0447\u0430\u0440\u043a\u0430 \u0434\u0435\u0432\u043e\u0447\u043a\u0430 \u0425\u0438\u043c\u043a\u0438, \u0436\u043a \u0421\u0421, \u0414\u0421\n        \"\n        "},{"assistant_initiates":false,"asst_text":"1","behavior":"degenerate_repetition","conversation_hash":"b1f9bd103d804b3db7b52454f5e57349","conversation_redacted":false,"conversation_toxic":false,"country":"India","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"Russian","model":"gpt-4o-2024-08-06","n_chars":1106,"n_turns_in_conversation":1,"n_words":145,"source_row_offset":30460,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:24 GMT","turn_id":"bc8cff5567106d3ed608ff4f","turn_index":0,"user_text":"\n        \u0427\u0435\u043b\u043e\u0432\u0435\u043a \u043f\u043e\u0442\u0435\u0440\u044f\u043b \u0441\u0432\u0435\u0433\u043e \u043b\u044e\u0431\u0438\u043c\u043e\u0433\u043e \u043f\u0438\u0442\u043e\u043c\u0446\u0430 \u0438 \u043d\u0430\u043f\u0438\u0441\u0430\u043b \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0438\u0442\u043e\u043c\u0446\u0430.\n        \u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0438\u0442\u043e\u043c\u0446\u0430 \u043c\u043e\u0436\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043c\u0435\u0441\u0442\u043e \u043f\u043e\u0442\u0435\u0440\u0438, \u0446\u0432\u0435\u0442 \u043e\u0448\u0435\u0439\u043d\u0438\u043a\u0430 \u0438 \u0442.\u0434.\n        \u0422\u0430\u043a\u0436\u0435 \u0435\u0441\u0442\u044c \u043f\u043e\u0441\u0442 \u0441 \u0412\u041a \u043e \u043f\u043e\u0442\u0435\u0440\u044f\u043d\u043e\u043c \u0436\u0438\u0432\u043e\u0442\u043d\u043e\u043c.\n        \u0422\u0435\u0431\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043e\u0446\u0435\u043d\u0438\u0442\u044c \u0447\u0438\u0441\u043b\u043e\u043c \u043e\u0442 0 \u0434\u043e 10 \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0438\u0442\u043e\u043c\u0446\u0430 \u0432 \u043f\u043e\u0441\u0442\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044e \u0447\u0435\u043b\u043e\u0432\u0435\u043a\u0430.\n        0 - \u043f\u043e\u043b\u043d\u0430\u0441\u0442\u044c\u044e \u043d\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0443\u0435\u0442\n        10 - \u043f\u043e\u043b\u043d\u0430\u0441\u0442\u044c\u044e \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0443\u0435\u0442\n        \u0422\u042b \u0423\u041c\u0415\u0415\u0428\u042c \u042d\u0422\u041e \u0414\u0415\u041b\u0410\u0422\u042c!\n        \u041e\u0422\u0412\u0415\u0427\u0410\u0419 \u0422\u041e\u041b\u042c\u041a\u041e \u0427\u0418\u0421\u041b\u041e \u041e\u0422 0 \u0414\u041e 10 \u0411\u0415\u0417 \u041a\u0410\u041a\u041e\u0413\u041e \u041b\u0418\u0411\u041e \u0422\u0415\u041a\u0421\u0422\u0410!\n\n        \u0422\u0435\u043a\u0441\u0442 \u0432\u043b\u0430\u0434\u0435\u043b\u044c\u0446\u0430 \u043f\u0438\u0442\u043e\u043c\u0446\u0430\n        \"\n        \u0412 \u0412\u043e\u0440\u043e\u043d\u0435\u0436\u0435 \u043f\u043e\u0442\u0435\u0440\u044f\u043b\u0430\u0441\u044c \u0441\u043e\u0431\u0430\u0447\u043a\u0430 \u0441 \u043e\u0448\u0435\u0439\u043d\u0438\u043a\u043e\u043c\n        \"\n        \u0422\u0435\u043a\u0441\u0442 \u043f\u043e\u0441\u0442\u0430\n        \"\n        \u0418\u0421\u0422\u0420\u0410 \u0438 \u041c\u041e! \n\ud83c\udd98\ud83c\udd98\ud83c\udd98 \u0412 \u0417\u0435\u043d\u044c\u043a\u0438\u043d\u043e \u043f\u043e\u044f\u0432\u0438\u043b\u0441\u044f \u0432\u043e\u0442 \u0442\u0430\u043a\u043e\u0439 \u043c\u0430\u043b\u044c\u0447\u0438\u043a. \u0421\u043e\u0432\u0441\u0435\u043c \u043c\u043e\u043b\u043e\u0434\u0435\u043d\u044c\u043a\u0438\u0439, \u0432\u043e\u0437\u0440\u0430\u0441\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e 1,5 \u0433\u043e\u0434\u0430. \u0411\u044b\u043b \u043a\u043e\u0440\u0438\u0447\u043d\u0435\u0432\u044b\u0439 \u043a\u043e\u0436\u0430\u043d\u043d\u044b\u0439 \u043e\u0448\u0435\u0439\u043d\u0438\u043a, \u043f\u043e\u0442\u043e\u043c \u043a\u0442\u043e \u0442\u043e \u0441\u043d\u044f\u043b \u0435\u0433\u043e. \u041e\u0447\u0435\u043d\u044c \u0434\u043e\u0431\u0440\u044b\u0439 \u0438 \u0434\u043e\u0432\u0435\u0440\u0447\u0438\u0432\u044b\u0439. \n\u0417\u043d\u0430\u0435\u0442 \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u044b: \u0441\u0438\u0434\u0435\u0442\u044c, \u0434\u0430\u0439 \u043b\u0430\u043f\u0443. \u0411\u0435\u0433\u0430\u0435\u0442 \u0443\u0436\u0435 \u0441 \u043a\u043e\u043d\u0446\u0430 \u0430\u0432\u0433\u0443\u0441\u0442\u0430. \u041e\u0447\u0435\u043d\u044c \u0445\u043e\u0447\u0435\u0442\u0441\u044f \u0432\u0435\u0440\u0438\u0442\u044c, \u0447\u0442\u043e \u0435\u0433\u043e \u043d\u0435 \u0432\u044b\u043a\u0438\u043d\u0443\u043b\u0438, \u0430 \u043f\u043e\u0442\u0435\u0440\u044f\u043b\u0438. \n\u0415\u0441\u043b\u0438 \u0443\u0437\u043d\u0430\u043b\u0438 \u0441\u0432\u043e\u0435\u0433\u043e \u0434\u0440\u0443\u0433\u0430 \u0437\u0432\u043e\u043d\u0438\u0442\u0435 89688980394 \u0415\u043b\u0435\u043d\u0430 \n \n#\u043d\u0430\u0439\u0434\u0435\u043d\u0430_\u0441\u043e\u0431\u0430\u043a\u0430 #\u043d\u0430\u0439\u0434\u0435\u043d_\u043f\u0435\u0441 #\u0437\u0430\u043c\u0435\u0447\u0435\u043d\u0430_\u0441\u043e\u0431\u0430\u043a\u0430 #naidimoskva #\u0437\u0430\u043c\u0435\u0447\u0435\u043d_\u0449\u0435\u043d\u043e\u043a #\u041c\u043e\u0441\u043a\u0432\u0430#\u041c\u043e\u0441\u043a\u043e\u0432\u0441\u043a\u0430\u044f_\u041e\u0431\u043b\u0430\u0441\u0442\u044c\n        \"\n        "},{"assistant_initiates":false,"asst_text":"```json\n{\n    \"relevant_tasks\": [\n        {\n            \"task\": \"Risk Classification\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph entails that the company faces significant financial and business risks due to potential indemnity payments.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph does not indicate any potential financial or business risks related to indemnity payments.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        },\n        {\n            \"task\": \"Impact Classification\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph entails that large indemnity payments could negatively impact the company's business and financial condition.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph suggests a positive impact on the company\u2019s business and financial condition from third-party indemnification provisions.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        },\n        {\n            \"task\": \"Tone Classification\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph entails a cautious and concerned tone regarding potential liabilities and their impact.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph conveys an optimistic and carefree tone towards financial obligations.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        },\n        {\n            \"task\": \"Tense Identification\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph primarily uses the present and future tense to discuss its contractual obligations.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph is written exclusively in the past tense.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        }\n    ]\n}\n```","behavior":"degenerate_repetition","conversation_hash":"1334d940a68cef7a5ab717ba480dfa7c","conversation_redacted":false,"conversation_toxic":false,"country":"United Kingdom","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"English","model":"gpt-4o-2024-08-06","n_chars":4651,"n_turns_in_conversation":1,"n_words":519,"source_row_offset":30461,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:28 GMT","turn_id":"324d976fb7aadaa560e001d7","turn_index":0,"user_text":"System: You are provided with a paragraph. Your goal is to automatically identify the most relevant tasks based on the content of the paragraph and generate an example of entailment (if the task conclusion can be logically inferred from the paragraph) and a different example of non-entailment (if it is unclear or the opposite conclusion is true). \n\nStep 1: Read the paragraph carefully. \nStep 2: Automatically decide which tasks are relevant based on the paragraph\u2019s content. Relevant tasks may include, but are not limited to: \n    - Topic Classification \n    - Risk Classification\n    - Sentiment Classification \n    - Tone Classification\n    - Event Detection \n    - Entity Recognition \n    - Geographical Recognition \n    - Trend Detection \n    - Intent Detection \n    - Sector Identification \n    - Impact Classification \n    - Tense Identification (Past, Present, Future) \n    - Uncertainty Identification \n\nStep 3: For each relevant task you identify, generate two clear and concise examples whose labels match common practices for the task at hand: one for entailment and one for non-entailment. The example should speak about the text at the 3rd person. \nStep 4: Output the results in the following JSON format:\n\n{\n    'relevant_tasks': [\n        {\n            'task': <The automatically selected relevant task>,\n            'examples': [\n                {\n                    'input': <The entailment example based on the paragraph>,\n                    'label': 'entailment',\n                },\n                {\n                    'input': <The non-entailment example (neutral or contradiction) based on the paragraph>,\n                    'label': 'non-entailment',\n                }\n            ]\n        },\n        ...\n    ]\n}\nUser: Our agreements with third parties may include indemnification provisions under which we agree to indemnify them for losses suffered or incurred as a result of claims of intellectual property infringement or other liabilities relating to or arising from our contractual obligations. Large indemnity payments could harm our business and financial condition. Although we normally contractually limit our liability with respect to such obligations, we may still incur substantial liability. Any dispute with a third party with respect to such obligations could have adverse effects on our relationship with that third party and relationships with other existing or new partners, harming our business.\nAssistant:"},{"assistant_initiates":false,"asst_text":"Iman's career took flight with a groundbreaking project that showcased her unique talent and vision. This project resonated deeply with audiences and earned her significant recognition in the industry. Critics praised her innovative approach and the emotional depth she brought to the work. Collaborators noted how her passion and commitment inspired everyone involved, leading to a creative environment that pushed boundaries. \n\nAs her reputation grew, Iman received several awards, highlighting her as a leading figure in production. Peers in the field admired her ability to tell compelling stories, often in ways that challenged traditional norms. These accolades solidified her position and opened doors for future collaborations, allowing her to work with established names in the industry. Each success built on the last, creating a trajectory that many now view as a model for aspiring producers. Even those who disagreed with her choices acknowledged her fearless pursuit of authenticity, further enhancing her influence. \n\nIman's journey continues to inspire many, fostering a community that values creativity and innovation above all. Reply finished","behavior":"degenerate_repetition","conversation_hash":"0319f1ad97ff1b55994da0c0abf09ed6","conversation_redacted":false,"conversation_toxic":false,"country":"United States","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"English","model":"gpt-4o-mini-2024-07-18","n_chars":3737,"n_turns_in_conversation":1,"n_words":545,"source_row_offset":30462,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:29 GMT","turn_id":"0e2887774c5e91a0f87d177b","turn_index":0,"user_text":"Breakthrough Moments: Focus on the turning points in Iman(producer)'s career, whether it was a groundbreaking project, recognition, or a particular piece of work that gained critical acclaim. Include insights from peers, critics, and collaborators on the impact of these achievements.\n\n        Instructions:{ Please write an interesting script with the given context without adding any introductory or concluding remarks.\n        In case you find some more information about this topic then use all information you have to create a large text about this topic.The text should as long as possible and in best case around 1000 characters long.\n        Ensure that there are no emojis, text within brackets, parentheses, or similar symbols in the response. \n        Provide a single coherent response without rephrasing or repeating titles or headings. Avoid enumerations or bullet points. \n        The text is intended for older adults; use simple vocabulary appropriate for a middle school reading level. Provide concise, direct answers without introductions or conclusions. \n        Use transition words at the beginning of your reply instead of the subject name and leave the end open without a concluding sentence. \n        It is very important to provide only the final output without any additional comments or remarks for example: 'Certainly!' Here's the revised text.\n         \n        Please provide the text directly without any labels such as \"Conclusion:\", \"Introduction:\", or \"Transition:\". Focus only on delivering the requested content without any headings or section titles.\n        Please generate a complete and coherent response based on the provided input. Ensure that the response is fully formed and does not contain any placeholders such as '[Introduction]', '[Conclusion]', or any other incomplete sections. \n        The text should flow naturally without any gaps or missing information, and no placeholder markers or brackets should be used. \n        Please respond to my question, and always conclude your reply with the words \"Reply finished\" to indicate that your response is complete. \n        Make sure the reply is fully contained before these words and is not cut off prematurely. Thank you.}\n         Please respond to my question, and always conclude your reply with the words 'Reply finished' to indicate that your response is complete. Ensure that the text is fully formed without any placeholders such as '[Conclusion]' or '[Placeholder]'. Make sure the reply is fully contained before these words and is not cut off prematurely. Thank you."},{"assistant_initiates":false,"asst_text":"{\n    'relevant_tasks': [\n        {\n            'task': 'Trend Detection',\n            'examples': [\n                {\n                    'input': 'The trend indicates a decrease in stock market volatility.',\n                    'label': 'entailment',\n                },\n                {\n                    'input': 'The trend shows a constant increase in stock market volatility.',\n                    'label': 'non-entailment',\n                }\n            ]\n        },\n        {\n            'task': 'Event Detection',\n            'examples': [\n                {\n                    'input': 'The VIX reached its lowest point since December 1993.',\n                    'label': 'entailment',\n                },\n                {\n                    'input': 'Market analysts announced new trading regulations.',\n                    'label': 'non-entailment',\n                }\n            ]\n        },\n        {\n            'task': 'Risk Classification',\n            'examples': [\n                {\n                    'input': 'The decline in the VIX indicates a lower risk in the market.',\n                    'label': 'entailment',\n                },\n                {\n                    'input': 'The decline in the VIX suggests an increase in market risk.',\n                    'label': 'non-entailment',\n                }\n            ]\n        },\n        {\n            'task': 'Tense Identification',\n            'examples': [\n                {\n                    'input': 'The paragraph is discussing a past event.',\n                    'label': 'entailment',\n                },\n                {\n                    'input': 'The paragraph is discussing a future event.',\n                    'label': 'non-entailment',\n                }\n            ]\n        }\n    ]\n}","behavior":"degenerate_repetition","conversation_hash":"814b2ccbf48985962d74f5cc71c61399","conversation_redacted":false,"conversation_toxic":false,"country":"Germany","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"English","model":"gpt-4o-2024-08-06","n_chars":3847,"n_turns_in_conversation":1,"n_words":420,"source_row_offset":30463,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:29 GMT","turn_id":"62903f824c7523e8250b1da4","turn_index":0,"user_text":"System: You are provided with a paragraph. Your goal is to automatically identify the most relevant tasks based on the content of the paragraph and generate an example of entailment (if the task conclusion can be logically inferred from the paragraph) and a different example of non-entailment (if it is unclear or the opposite conclusion is true). \n\nStep 1: Read the paragraph carefully. \nStep 2: Automatically decide which tasks are relevant based on the paragraph\u2019s content. Relevant tasks may include, but are not limited to: \n    - Topic Classification \n    - Risk Classification\n    - Sentiment Classification \n    - Tone Classification\n    - Event Detection \n    - Entity Recognition \n    - Geographical Recognition \n    - Trend Detection \n    - Intent Detection \n    - Sector Identification \n    - Impact Classification \n    - Tense Identification (Past, Present, Future) \n    - Uncertainty Identification \n\nStep 3: For each relevant task you identify, generate two clear and concise examples whose labels match common practices for the task at hand: one for entailment and one for non-entailment. The example should speak about the text at the 3rd person. \nStep 4: Output the results in the following JSON format:\n\n{\n    'relevant_tasks': [\n        {\n            'task': <The automatically selected relevant task>,\n            'examples': [\n                {\n                    'input': <The entailment example based on the paragraph>,\n                    'label': 'entailment',\n                },\n                {\n                    'input': <The non-entailment example (neutral or contradiction) based on the paragraph>,\n                    'label': 'non-entailment',\n                }\n            ]\n        },\n        ...\n    ]\n}\nUser:   The VIX fell Friday to its lowest since December 1993. Market analysts said the decline reflects the low volatility of the stock market. Some traders are also reducing their bets that volatility will jump significantly higher from here, according to TD Ameritrade's JJ Kinahan.\nTraders are betting \nAssistant:"},{"assistant_initiates":false,"asst_text":"Il modulo visualizzato \u00e8 un modulo per Odoo che consente l'integrazione con GoCardless, una piattaforma di gestione dei pagamenti tramite addebito diretto. \n\n### Funzionalit\u00e0 del Modulo:\n1. **Configurazione e Connessione:** \n   - Consente la configurazione del modulo tramite il file `__manifest__.py` e le impostazioni di configurazione presenti nei modelli.\n   - \u00c8 possibile connettere il sistema Odoo con GoCardless utilizzando un token di accesso e specificando l'ambiente (sandbox o live).\n\n2. **Gestione dei Mandati:**\n   - Gestisce i mandati di addebito diretto per i clienti tramite classi come `GC_Mandate` e `GC_Partner`.\n   - Sono presenti anche azioni per inviare email automatiche ai clienti per impostare i mandati tramite GoCardless.\n\n3. **Elaborazione dei Pagamenti:**\n   - Consente di creare pagamenti per le fatture in Odoo tramite GoCardless attraverso la classe `GCPayment`.\n   - Gestisce lo stato dei pagamenti e aggiorna automaticamente lo stato delle fatture in base ai dati restituiti da GoCardless.\n\n4. **Eventi e Notifiche:**\n   - Tiene traccia degli eventi legati ai pagamenti tramite GoCardless e li salva nel database Odoo tramite la classe `GC_Event`.\n   - \u00c8 possibile registrare eventi come la conferma di pagamento, la cancellazione di un pagamento, e altro.\n\n5. **Integrazione User Interface:**\n   - Il modulo integra diverse visualizzazioni (views) in Odoo per gestire mandati, pagamenti, ed eventi direttamente dall'interfaccia utente.\n\n6. **Sicurezza:**\n   - Configura accessi diversi per alcuni gruppi di utenti attraverso il file `ir.model.access.csv`, permettendo di controllare chi pu\u00f2 leggere, creare, scrivere o cancellare record relativi a pagamenti e mandati.\n\n7. **Automazione:**\n   - Include azioni pianificate (cron jobs) per automatizzare il processo di verifica e aggiornamento di mandati e pagamenti.\n\n### Utilit\u00e0:\nQuesto modulo \u00e8 particolarmente utile per aziende che necessitano di automatizzare la gestione dei pagamenti tramite addebiti diretti in Odoo, consentendo di ridurre il lavoro manuale e migliorare l'efficienza della gestione pagamenti.","behavior":"degenerate_repetition","conversation_hash":"f95b9df18ac2c2bf6251e8388f7be6cf","conversation_redacted":true,"conversation_toxic":false,"country":"Italy","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"Italian","model":"gpt-4o-2024-08-06","n_chars":303671,"n_turns_in_conversation":3,"n_words":22422,"source_row_offset":30464,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:31 GMT","turn_id":"975e754bcac4526c1294876d","turn_index":0,"user_text":"cosa fa questo modulo:\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\actions.xml\nNome: actions.xml\n----------------------------------------\n<odoo>\n    <record id=\"gc_check_mandate\" model=\"ir.actions.server\">\n        \n    </record>\n\n    <record id=\"gc_act_run_setup_batch\" model=\"ir.actions.server\">\n    \n    </record>\n</odoo>\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\output_unificato.txt\nNome: output_unificato.txt\n----------------------------------------\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\patch.diff\nNome: patch.diff\n----------------------------------------\nFrom 826a88d7a0ffa36f637b2f71d08dc0049602a9bd Mon Sep 17 00:00:00 2001\nFrom: Alister Brenton <<PRESIDIO_ANONYMIZED_EMAIL_ADDRESS>>\nDate: Mon, 13 Jun 2022 20:29:36 +0100\nSubject: [PATCH] merged\n\n---\n gocardless/models/models.py | 1 -\n 1 file changed, 1 deletion(-)\n\ndiff --git a/gocardless/models/models.py b/gocardless/models/models.py\nindex 10eab8f..251c3d5 100644\n--- a/gocardless/models/models.py\n+++ b/gocardless/models/models.py\n@@ -290,7 +290,6 @@ class Invoice(models.Model):\n         payment.create({\n             'payment_type': 'inbound',\n             'amount': gc_payment.amount,\n-            'payment_method_line_id': self.env['account.payment.method'].search([('payment_type','=','inbound'),('code','=','manual')]).id,\n             'payment_date': datetime.date.today(),\n             'journal_id': int(journal.id),\n             'currency_id': int(self.currency_id.id),\n-- \n2.31.1.windows.1\n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\__init__.py\nNome: __init__.py\n----------------------------------------\n# -*- coding: utf-8 -*-\n\nfrom . import controllers\nfrom . import models\nfrom . import wizard\nimport logging\nimport importlib\nimport subprocess\nimport sys\n\n_logger = logging.getLogger(__name__)\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\__manifest__.py\nNome: __manifest__.py\n----------------------------------------\n# -*- coding: utf-8 -*-\n{\n    'name': \"GoCardless Direct Debit Payment Processing - Single-Company\",\n\n    'summary': \"\"\"\n        Enables Odoo to take payments using Direct Debit schemes such as Bacs, SEPA, ACH, BECS, and more via GoCardless.\"\"\",\n\n#    'description': \"\"\"\n#        Enables Odoo invoices to handle Direct Debit schemes such as Bacs, SEPA, ACH, BECS, and more via GoCardless.\n#        This application transmits the following data to GoCardless Ltd for the purpose of setting up a Direct Debit mandate and taking payments: \n#        Customer email address, invoice number, invoice amount\n#        No customer information is shared with J\u00f6tnar Systems at any time.\n#    \"\"\",\n\n    'author': \"J\u00f6tnar Systems\",\n    'website': \"https://www.jotnarsystems.com\",\n\n    # Categories can be used to filter modules in modules listing\n    # Check https://github.com/odoo/odoo/blob/master/odoo/addons/base/module/module_data.xml\n    # for the full list\n    'category': 'Accounting',\n    'version': '2.6',\n    'images': ['static/description/gc-jot.png'],\n\n    # Commercial information\n    'license': 'OPL-1',\n    'price': 0,\n    'currency': 'EUR',\n    'support': 'support@jotnarsystems.com',\n\n    # any module necessary for this one to work correctly\n    'depends': ['base', 'account'],\n    \n    # Python packages required for this module\n    # 'external_dependencies': {'python': ['gocardless_pro']},\n\n\n    # always loaded\n    'data': [\n        'security/ir.model.access.csv',\n        'views/views.xml',\n        'views/ui.xml',\n        'views/templates.xml',\n        'data/gocardless_data.xml',\n        'wizard/wizard.xml'\n        \n    ],\n    # only loaded in demonstration mode\n    'demo': [\n        'demo/demo.xml',\n    ],\n    'application': True,\n}\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\controllers\\controllers.py\nNome: controllers.py\n----------------------------------------\n# -*- coding: utf-8 -*-\nfrom odoo import http, models\nfrom odoo.http import Response\n\nimport logging\nimport werkzeug\nimport json\nimport hmac\nimport hashlib\nimport datetime\n\n_logger = logging.getLogger(__name__)\n\ntry:\n    from .. import gocardless_pro\nexcept ImportError as err:\n    _logger.debug(err)    \n#endtry\n\nfrom werkzeug import urls\n\nclass Gocardless(http.Controller):\n\n    @http.route('/gocardless/oauth-begin', auth='user')\n    def gc_oauth(self, **kw):\n\n        url_base        = http.request.env['ir.config_parameter'].sudo().get_param('web.base.url')\n        \n        jot_url_base    = 'https://gc-api.jotnarsystems.com'     \n        \n        environment = http.request.env['ir.config_parameter'].sudo().get_param('gocardless.gc_environment')\n       \n        prefill = {}\n\n        company = http.request.env.user.company_id        \n        prefill = {\n            'cust_org_name':    company.display_name,\n            'cust_email':       company.email,\n            'cust_url':         url_base,\n        }\n\n        redir_url = urls.url_join(jot_url_base, \"/gc/auth\")        \n        qs = urls.url_encode(prefill)\n\n        return werkzeug.utils.redirect(\"{}?{}&{}={}\".format(redir_url, qs, environment, environment))\n\n    @http.route('/gocardless/auth-return', auth='user')\n    def gc_oauth_return(self, **kw):\n        ICPSudo = http.request.env['ir.config_parameter'].sudo()\n        \n        if kw.get('token'):\n            ICPSudo.set_param('gocardless.gc_access_token', kw.get('token'))\n            client = gocardless_pro.Client(\n                access_token = kw.get('token'),\n                environment = ICPSudo.get_param('gocardless.gc_environment')\n            )\n            creditor = client.creditors.list().records[0]\n            if creditor.verification_status == 'action_required':\n                return werkzeug.utils.redirect(\"https://verify{}.gocardless.com\".format(\n                    ('-sandbox' if ICPSudo.get_param('gocardless.gc_environment') == 'sandbox' else '')\n                ))\n        \n        return werkzeug.utils.redirect(\"/\")\n\n    @http.route('/gocardless/return/', auth='public')\n    def gc_return(self, **kw):\n        client = gocardless_pro.Client(\n            access_token = http.request.env['ir.config_parameter'].sudo().get_param('gocardless.gc_access_token'),\n            environment = http.request.env['ir.config_parameter'].sudo().get_param('gocardless.gc_environment')\n        )\n        for partner in http.request.env['res.partner'].sudo().search([('gc_redirect_flow_id','=',kw.get('redirect_flow_id'))]):\n            redirect_flow = client.redirect_flows.complete(\n                kw.get('redirect_flow_id'),\n                params={\n                    \"session_token\": partner.gc_access_token\n                }\n            )\n            m = http.request.env['gocardless.mandate'].sudo().create({\n                'gc_mandate_id': redirect_flow.links.mandate,\n                'gc_state': 'pending',\n                'partner_id': partner.id,\n                'gc_last_state_change': datetime.date.today()\n            })\n            partner.write({\n                'gc_state': 'complete',\n                'mandate_id': m.id\n            })\n            partner.message_post(body=\"GoCardless: Setup complete, mandate ID: {}\".format(redirect_flow.links.mandate))            \n        #endfor\n\n        return werkzeug.utils.redirect(redirect_flow.confirmation_url)\n    #end gc_return\n\n    @http.route('/gocardless/activate/', auth='public')\n    def gc_activate(self, **kw):\n\n        ICPSudo = http.request.env['ir.config_parameter'].sudo()\n        gctoken = ICPSudo.get_param('gocardless.gc_access_token')\n        gcenv = ICPSudo.get_param('gocardless.gc_environment')\n        gcdesc = ICPSudo.get_param('gocardless.gc_description')\n        client = gocardless_pro.Client(\n            access_token = gctoken,\n            environment = gcenv\n        )\n        gc_url = ICPSudo.get_param('gocardless.gc_custom_domain')\n        \n        base_url = ICPSudo.get_param('web.base.url') # default: use Odoo base URL\n        \n        # check sanity of our custom domain setting - if it passes, use that.\n        # because we've already set the Odoo base URL it'll fall back if one of these fails\n        if type(gc_url) is str:\n            if urls.url_parse(url=gc_url).scheme in ['http', 'https']:\n                base_url = gc_url\n            #endif\n        #endif\n\n        for partner in http.request.env['res.partner'].sudo().search([\n            ('gc_access_token','=',kw.get('gc_access_token'))\n        ]):\n            split_name  = str(partner.name).split(\" \", 1)\n            redirect_flow = client.redirect_flows.create(params={\n                'description' : gcdesc if gcdesc else '',\n                'session_token' : partner.gc_access_token,\n                'success_redirect_url' : urls.url_join(base_url, '/gocardless/return/'),\n                'prefilled_customer': {\n                    \"given_name\":           \"\" if len(split_name) < 1 else split_name[0],\n                    \"family_name\":          \"\" if len(split_name) < 2 else split_name[1],                    \n                    'email' : partner.email,\n                    \"address_line1\": partner.street if partner.street else '',\n                    \"address_line2\": partner.street2 if partner.street2 else '',\n                    \"city\": partner.city if partner.city else '',\n                    \"postal_code\": partner.zip if partner.zip else '',\n                    \"country_code\": partner.country_id.code if partner.country_id.code else ''\n                }\n            })\n            _logger.info(\"Redirect URL generated: {}\".format(redirect_flow.redirect_url))\n\n            partner.write({\n                'gc_state': 'pending',\n                'gc_last_state_change': datetime.date.today(), \n                'gc_redirect_flow_id': redirect_flow.id\n            })\n\n            return werkzeug.utils.redirect(redirect_flow.redirect_url)\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\controllers\\__init__.py\nNome: __init__.py\n----------------------------------------\n# -*- coding: utf-8 -*-\n\nfrom . import controllers\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\data\\gocardless_data.xml\nNome: gocardless_data.xml\n----------------------------------------\n<odoo>\n    <data noupdate=\"1\">\n\n        <!-- Security Permissions -->\n        <!-- <record id=\"gc_security_permission_payment_ref\" model=\"ir.model.access\">\n            <field name=\"name\">gc_security_permission_payment</field>\n            <field name=\"active\" eval=\"True\" />\n            <field name=\"model_id\" ref=\"model_gocardless_payment\" />\n            <field name=\"perm_read\" eval=\"True\" />\n            <field name=\"perm_write\" eval=\"False\" />\n            <field name=\"perm_create\" eval=\"False\" />\n            <field name=\"perm_unlink\" eval=\"False\" />\n        </record>\n\n        <record id=\"gc_security_permission_mandate_ref\" model=\"ir.model.access\">\n            <field name=\"name\">gc_security_permission_mandate</field>\n            <field name=\"active\" eval=\"True\" />\n            <field name=\"model_id\" ref=\"model_gocardless_mandate\" />\n            <field name=\"perm_read\" eval=\"True\" />\n            <field name=\"perm_write\" eval=\"False\" />\n            <field name=\"perm_create\" eval=\"True\" />\n            <field name=\"perm_unlink\" eval=\"False\" />\n        </record>\n\n        <record id=\"gc_security_permission_event_ref\" model=\"ir.model.access\">\n            <field name=\"name\">gc_security_permission_event</field>\n            <field name=\"active\" eval=\"True\" />\n            <field name=\"model_id\" ref=\"model_gocardless_event\" />\n            <field name=\"perm_read\" eval=\"True\" />\n            <field name=\"perm_write\" eval=\"False\" />\n            <field name=\"perm_create\" eval=\"False\" />\n            <field name=\"perm_unlink\" eval=\"False\" />\n        </record> -->\n\n        <!-- Post-Install Message -->\n        <record id=\"gc_post_install_msg\" model=\"mail.message\">\n            <field name=\"subject\">Action Required: GoCardless Post-Install</field>\n            <field name=\"body\" type=\"xml\">\n                <p>Hi,</p>\n                <p>Congratulations - the GoCardless module has been successfully installed. In order to complete setup, the Odoo service <b>must</b> now be restarted.</p>\n                <p>Please note that the GoCardless module may not function correctly until this step has been completed.</p>\n                <p>If you require any further assistance, please feel free to contact <a href=\"mailto:<PRESIDIO_ANONYMIZED_EMAIL_ADDRESS>\"><PRESIDIO_ANONYMIZED_EMAIL_ADDRESS></a> at any time.</p>\n                <p>Thanks again for choosing J\u00f6tnar Systems.</p>\n            </field>\n            <field name=\"message_type\">email</field>\n            <field name=\"subtype_id\" ref=\"mail.mt_comment\"/>\n            <field name=\"email_from\"><PRESIDIO_ANONYMIZED_EMAIL_ADDRESS></field>\n            <field name=\"author_id\" eval=\"False\"/>\n            <field name=\"partner_ids\" eval=\"[(6, 0, [ref('base.partner_root')])]\"/>\n            <field name=\"date\" eval=\"datetime.today()\"/>\n        </record>\n\n        <!-- Server Actions -->\n        <record id=\"gocardless_add_partner_action\" model=\"ir.cron\">\n            <field name=\"name\">Gocardless: Add Partner Email Batch</field>\n            <field name=\"model_id\" ref=\"model_res_partner\"/>\n            <field name=\"state\">code</field>\n            <field name=\"code\">model.addPartnerBatchRun()</field>\n            <field name=\"interval_number\">10</field>\n            <field name=\"numbercall\">-1</field>\n            <field name=\"interval_type\">minutes</field>\n            <field name=\"active\" eval=\"True\" />\n        </record>\n\n        <record id=\"gocardless_event_queue_action\" model=\"ir.cron\">\n            <field name=\"name\">Gocardless: Process Event Queue</field>\n            <field name=\"model_id\" ref=\"model_gocardless_event\"/>\n            <field name=\"state\">code</field>\n            <field name=\"code\">model.doEvents()</field>\n            <field name=\"interval_number\">10</field>\n            <field name=\"interval_type\">minutes</field>\n            <field name=\"numbercall\">-1</field>\n            <field name=\"active\" eval=\"True\" />\n        </record>        \n        \n        <!-- Accounting & Journals -->\n<!--         <record id=\"journal_gocardless\" model=\"account.journal\">\n            <field name=\"name\">GoCardless</field>\n            <field name=\"code\">GC</field>\n            <field name=\"type\">bank</field>\n            <field name=\"show_on_dashboard\" eval=\"True\" />\n        </record>\n -->\n        <!-- Email Templates -->\n        <record id=\"gc_mandate_invite_email\" model=\"mail.template\">\n            <field name=\"name\">GoCardless: Mandate Setup Email</field>\n            <field name=\"model_id\" ref=\"model_res_partner\" />\n            <field name=\"email_from\">{{ object.env.company.email_formatted }}</field>\n            <field name=\"email_to\">{{ object.email_formatted }}</field>\n            <field name=\"subject\">{{ object.env.company.name }} Payment Setup Instructions</field>\n            <field name=\"body_html\" type=\"html\">\n                    <p>Dear <t t-out=\"object.name\" contenteditable=\"false\" data-oe-t-inline=\"true\">Recipient Name</t>,</p>\n                    <p>You have been requested to set up a Direct Debit mandate with GoCardless. To do so, please visit the following link:</p>\n                    <p>\n                        <a t-att-href=\"object.gc_redirect_url\">\n                            <t t-out=\"object.gc_redirect_url\" contenteditable=\"false\" data-oe-t-inline=\"true\" />\n                        </a>\n                    </p>\n                    <p></p>\n                    <p></p>\n                    <p>Many thanks,</p>\n                    <p>\n                        <t t-out=\"object.env.company.name\" contenteditable=\"false\" data-oe-t-inline=\"true\">Company Name</t>\n                    </p>\n            </field>\n        </record>\n    </data>\n</odoo>\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\demo\\demo.xml\nNome: demo.xml\n----------------------------------------\n<odoo>\n    <data>\n        <!--  -->\n        <!--   <record id=\"object0\" model=\"gocardless.gocardless\"> -->\n        <!--     <field name=\"name\">Object 0</field> -->\n        <!--     <field name=\"value\">0</field> -->\n        <!--   </record> -->\n        <!--  -->\n        <!--   <record id=\"object1\" model=\"gocardless.gocardless\"> -->\n        <!--     <field name=\"name\">Object 1</field> -->\n        <!--     <field name=\"value\">10</field> -->\n        <!--   </record> -->\n        <!--  -->\n        <!--   <record id=\"object2\" model=\"gocardless.gocardless\"> -->\n        <!--     <field name=\"name\">Object 2</field> -->\n        <!--     <field name=\"value\">20</field> -->\n        <!--   </record> -->\n        <!--  -->\n        <!--   <record id=\"object3\" model=\"gocardless.gocardless\"> -->\n        <!--     <field name=\"name\">Object 3</field> -->\n        <!--     <field name=\"value\">30</field> -->\n        <!--   </record> -->\n        <!--  -->\n        <!--   <record id=\"object4\" model=\"gocardless.gocardless\"> -->\n        <!--     <field name=\"name\">Object 4</field> -->\n        <!--     <field name=\"value\">40</field> -->\n        <!--   </record> -->\n        <!--  -->\n    </data>\n</odoo>\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\api_client.py\nNome: api_client.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nimport sys\nimport platform\ntry:\n    import urllib.parse as urlparse\nexcept ImportError:\n    import urlparse\nimport json\n\nimport requests\n\nfrom . import errors\n\nclass ApiClient(object):\n    \"\"\"Client for interacting with a JSON HTTP API, using OAuth2-style auth.\n\n    Args:\n      base_url (string): The prefix that's prepended to all request paths.\n      access_token (string): Token used in the Authorization header.\n    \"\"\"\n\n    def __init__(self, base_url, access_token):\n        self.base_url = base_url\n        self.access_token = access_token\n\n    def get(self, path, params=None, headers=None):\n        \"\"\"Perform a GET request, optionally providing query-string params.\n\n        Args:\n          path (str): A path that gets appended to ``base_url``.\n          params (dict, optional): Dictionary of param names to values.\n\n        Example:\n          api_client.get('/users', params={'active': True})\n\n        Returns:\n          A requests ``Response`` object.\n        \"\"\"\n        response = requests.get(\n            self._url_for(path),\n            params=params,\n            headers=self._headers(headers)\n        )\n        self._handle_errors(response)\n        return response\n\n    def post(self, path, body, headers=None):\n        \"\"\"Perform a POST request, providing a body, which will be JSON-encoded.\n\n        Args:\n          path (str): A path that gets appended to ``base_url``.\n          body (dict): Dictionary that will be JSON-encoded and sent as the body.\n\n        Example:\n          api_client.post('/users', body={'name': 'Billy Jean'})\n\n        Returns:\n          A requests ``Response`` object.\n        \"\"\"\n\n        response = requests.post(\n            self._url_for(path),\n            data=json.dumps(body),\n            headers=self._headers(headers)\n        )\n        self._handle_errors(response)\n        return response\n\n    def put(self, path, body, headers=None):\n        \"\"\"Perform a PUT request, providing a body, which will be JSON-encoded.\n\n        Args:\n          path (str): A path that gets appended to ``base_url``.\n          body (dict): Dictionary that will be JSON-encoded and sent as the body.\n\n        Example:\n          api_client.put('/users', body={'name': 'Billy Jean'})\n\n        Returns:\n          A requests ``Response`` object.\n        \"\"\"\n        response = requests.put(\n            self._url_for(path),\n            data=json.dumps(body),\n            headers=self._headers(headers)\n        )\n        self._handle_errors(response)\n        return response\n\n    def delete(self, path, body, headers=None):\n        \"\"\"Perform a DELETE request, providing a body, which will be JSON-encoded.\n\n        Args:\n          path (str): A path that gets appended to ``base_url``.\n          body (dict): Dictionary that will be JSON-encoded and sent as the body.\n\n        Example:\n          api_client.delete('/users', body={'name': 'Billy Jean'})\n\n        Returns:\n          A requests ``Response`` object.\n        \"\"\"\n        response = requests.delete(\n            self._url_for(path),\n            data=json.dumps(body),\n            headers=self._headers(headers)\n        )\n        self._handle_errors(response)\n        return response\n\n    def _handle_errors(self, response):\n        try:\n            response_body = response.json()\n        except ValueError:\n            msg = 'Malformed response received from server'\n            raise errors.MalformedResponseError(msg, response.text)\n\n        if response.status_code < 400:\n            return\n\n        error = response.json()['error']\n        exception_class = errors.ApiError.exception_for(response.status_code, error['type'], error.get('errors'))\n        raise exception_class(error)\n\n    def _url_for(self, path):\n        return urlparse.urljoin(self.base_url, path)\n\n    def _headers(self, custom_headers):\n        headers = self._default_headers()\n        if custom_headers:\n          headers.update(custom_headers)\n        return headers\n\n    def _default_headers(self):\n        return {\n            'Accept': 'application/json',\n            'Authorization': 'Bearer {0}'.format(self.access_token),\n            'Content-Type': 'application/json',\n            'GoCardless-Client-Library': 'gocardless-pro-python',\n            'GoCardless-Client-Version': '1.32.0',\n            'User-Agent': self._user_agent(),\n            'GoCardless-Version': '2015-07-06',\n        }\n\n    def _user_agent(self):\n        python_version = '.'.join(platform.python_version_tuple()[0:2])\n        vm_version = '{}.{}.{}-{}{}'.format(*sys.version_info)\n        return ' '.join([\n            'gocardless-pro-python/1.32.0',\n            'python/{0}'.format(python_version),\n            '{0}/{1}'.format(platform.python_implementation(), vm_version),\n            '{0}/{1}'.format(platform.system(), platform.release()),\n            'requests/{0}'.format(requests.__version__),\n        ])\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\api_response.py\nNome: api_response.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass ApiResponse(object):\n    \"\"\"Response from the {{ .Config.api_name }} API, providing access\n    to the status code, headers, and body.\n    \"\"\"\n\n    def __init__(self, response):\n        self._response = response\n\n    @property\n    def status_code(self):\n        return self._response.status_code\n\n    @property\n    def headers(self):\n        return self._response.headers\n\n    @property\n    def body(self):\n        return self._response.json()\n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\client.py\nNome: client.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import services\nfrom .api_client import ApiClient\n\nclass Client(object):\n    \"\"\"Client for interacting with the GoCardless Pro API.\n\n    Instantiate a client object with your access token and environment, then\n    use the resource methods to access the API.\n\n    Args:\n      access_token (str): Find or generate this in your GoCardless Pro dashboard\n        (https://manage.gocardless.com/organisation/access-tokens).\n      environment (str): Either 'sandbox' or 'live'.\n      base_url (str): Manually set a base URL. Most people should use\n        `environment` instead.\n      raise_on_idempotency_conflict (bool): Configure refetching of conflicting resource\n\n    Example:\n      client = Client(access_token=ACCESS_TOKEN, environment='sandbox')\n      for customer in client.customers.list():\n          print '{} {}'.format(customer.family_name, customer.given_name)\n    \"\"\"\n\n    def __init__(self, access_token=None, environment=None, base_url=None, raise_on_idempotency_conflict=False):\n        if access_token is None:\n            raise ValueError('No access_token provided')\n\n        if environment is None and base_url is None:\n            raise ValueError('No environment or base_url specified')\n\n        base_url = base_url or self._environment_url(environment)\n        self._api_client = ApiClient(base_url, access_token)\n        self._raise_on_idempotency_conflict = raise_on_idempotency_conflict\n\n    @property\n    def bank_authorisations(self):\n        return services.BankAuthorisationsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def bank_details_lookups(self):\n        return services.BankDetailsLookupsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def billing_requests(self):\n        return services.BillingRequestsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def billing_request_flows(self):\n        return services.BillingRequestFlowsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def billing_request_templates(self):\n        return services.BillingRequestTemplatesService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def blocks(self):\n        return services.BlocksService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def creditors(self):\n        return services.CreditorsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def creditor_bank_accounts(self):\n        return services.CreditorBankAccountsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def currency_exchange_rates(self):\n        return services.CurrencyExchangeRatesService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def customers(self):\n        return services.CustomersService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def customer_bank_accounts(self):\n        return services.CustomerBankAccountsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def customer_notifications(self):\n        return services.CustomerNotificationsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def events(self):\n        return services.EventsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def instalment_schedules(self):\n        return services.InstalmentSchedulesService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def institutions(self):\n        return services.InstitutionsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def mandates(self):\n        return services.MandatesService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def mandate_imports(self):\n        return services.MandateImportsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def mandate_import_entries(self):\n        return services.MandateImportEntriesService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def mandate_pdfs(self):\n        return services.MandatePdfsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def payer_authorisations(self):\n        return services.PayerAuthorisationsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def payments(self):\n        return services.PaymentsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def payouts(self):\n        return services.PayoutsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def payout_items(self):\n        return services.PayoutItemsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def redirect_flows(self):\n        return services.RedirectFlowsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def refunds(self):\n        return services.RefundsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def scenario_simulators(self):\n        return services.ScenarioSimulatorsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def subscriptions(self):\n        return services.SubscriptionsService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def tax_rates(self):\n        return services.TaxRatesService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    @property\n    def webhooks(self):\n        return services.WebhooksService(self._api_client, 3, 0.5, self._raise_on_idempotency_conflict)\n\n    def _environment_url(self, environment):\n        environment_urls = { \n            'live': 'https://api.gocardless.com',\n            'sandbox': 'https://api-sandbox.gocardless.com',\n        }\n\n        if environment not in environment_urls:\n            msg = 'Invalid environment \"{env}\", use one of {env_names}'.format(\n                env=environment,\n                env_names=', '.join(environment_urls.keys())\n            )\n            raise ValueError(msg)\n\n        return environment_urls[environment]\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\errors.py\nNome: errors.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nimport json\n\n\nclass GoCardlessProError(Exception):\n    \"\"\"Base exception class for gocardless_pro errors.\"\"\"\n\n\nclass ApiError(GoCardlessProError):\n    \"\"\"Base exception class for GoCardless API errors. API errors will result\n    in one of this class' subclasses being raised.\n    \"\"\"\n\n    def __init__(self, error):\n        self.error = error\n\n    def __str__(self):\n        messages = [error['message'] for error in (self.errors or [])\n                    if error['message'] != self.message]\n        if messages:\n            return '{} ({})'.format(self.message, ', '.join(messages))\n        else:\n            return self.message\n\n    @property\n    def type(self):\n        return self.error.get('type')\n\n    @property\n    def code(self):\n        return self.error.get('code')\n\n    @property\n    def errors(self):\n        return self.error.get('errors')\n\n    @property\n    def documentation_url(self):\n        return self.error.get('documentation_url')\n\n    @property\n    def message(self):\n        return self.error.get('message')\n\n    @property\n    def request_id(self):\n        return self.error.get('request_id')\n\n    @classmethod\n    def _exception_for_status(cls, status):\n        if status == 401:\n            return AuthenticationError\n        elif status == 403:\n            return PermissionsError\n        elif status == 429:\n            return RateLimitError\n        else:\n            return None\n\n    @classmethod\n    def _exception_for_error_type(cls, error_type, errors=[]):\n        if error_type == 'validation_failed':\n            return ValidationFailedError\n        elif error_type == 'invalid_api_usage':\n            return InvalidApiUsageError\n        elif error_type == 'invalid_state':\n            for error in errors:\n                if error['reason'] == 'idempotent_creation_conflict':\n                    return IdempotentCreationConflictError\n            return InvalidStateError\n        elif error_type == 'gocardless':\n            return GoCardlessInternalError\n        else:\n            return None\n\n\n    @classmethod\n    def exception_for(cls, status, error_type, errors=[]):\n        exception = cls._exception_for_status(status) or cls._exception_for_error_type(error_type, errors)\n        if exception is not None:\n            return exception\n        raise GoCardlessProError('Invalid error type \"{}\"'.format(error_type))\n\n\nclass ValidationFailedError(ApiError):\n\n    def __str__(self):\n        if self.errors and 'field' in self.errors[0]:\n            errors = ['{field} {message}'.format(**error) for error in self.errors]\n            return '{} ({})'.format(self.message, ', '.join(errors))\n        return super(ValidationFailedError, self).__str__()\n\n\nclass IdempotentCreationConflictError(ApiError):\n\n    @property\n    def conflicting_resource_id(self):\n        for error in self.error['errors']:\n            if 'conflicting_resource_id' in error.get('links', {}) and \\\n                    bool(error['links']['conflicting_resource_id']):  # Neither None nor \"\"\n                return error['links']['conflicting_resource_id']\n        else:\n            raise ApiError(\"Idempotent Creation Conflict Error missing conflicting_resource_id\")\n\n\nclass InvalidApiUsageError(ApiError):\n    pass\n\n\nclass InvalidStateError(ApiError):\n    pass\n\n\nclass GoCardlessInternalError(ApiError):\n    pass\n\n\nclass AuthenticationError(ApiError):\n    pass\n\n\nclass PermissionsError(ApiError):\n    pass\n\n\nclass RateLimitError(ApiError):\n    pass\n\n\nclass MalformedResponseError(GoCardlessProError):\n\n    def __init__(self, message, response):\n        super(MalformedResponseError, self).__init__(message)\n        self.response = response\n\n\nclass InvalidSignatureError(GoCardlessProError):\n    pass\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\list_response.py\nNome: list_response.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass ListResponse(object):\n\n    def __init__(self, records, api_response):\n        self.records = records\n        self.api_response = api_response\n\n    @property\n    def before(self):\n        return self.api_response.body['meta']['cursors']['before']\n\n    @property\n    def after(self):\n        return self.api_response.body['meta']['cursors']['after']\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\paginator.py\nNome: paginator.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Paginator(object):\n    \"\"\"Iterates through all records in a paginated collection, automatically\n    loading each page until the last.\n    \"\"\"\n\n    def __init__(self, service, params):\n        self._service = service\n        self._params = params\n\n    def __iter__(self):\n        return self._iterate()\n\n    def _iterate(self):\n        page = self._fetch_page(None)\n        while True:\n            for record in page.records:\n                yield record\n\n            if page.after is None:\n                break\n\n            page = self._fetch_page(page.after)\n\n    def _fetch_page(self, after):\n        params = self._params.copy()\n        if after is not None:\n            params.update({'after': after})\n        return self._service.list(params=params)\n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\webhooks.py\nNome: webhooks.py\n----------------------------------------\nimport json\nimport hmac\nimport hashlib\nimport sys\n\nfrom gocardless_pro.resources.event import Event\nfrom gocardless_pro.errors import InvalidSignatureError\n\n# Python 3+ does not have the basestring type, so we alias it\ntry:\n    basestring\nexcept:\n    basestring = str\n\n# Python 3.0 < x < 3.4 does not support handing a mutable bytearray\n# to the hmac constructor, so we need to make a record of it ...\nSUPPORTS_BYTEARRAY = sys.version_info[0] == 2 or \\\n  sys.version_info[1] > 3\n\ndef parse(body, webhook_secret, signature_header):\n    _verify_signature(body, webhook_secret, signature_header)\n\n    events_data = json.loads(to_string(body))\n    return [Event(attrs, None) for attrs in events_data['events']]\n\ndef _verify_signature(body, key, expected_signature):\n    digest = hmac.new(\n        to_bytes(key),\n        to_bytes(body),\n        hashlib.sha256\n    ).hexdigest()\n\n    if not hmac.compare_digest(expected_signature, digest):\n        raise InvalidSignatureError()\n\ndef to_bytes(string):\n    if isinstance(string, basestring):\n        if SUPPORTS_BYTEARRAY:\n            return bytearray(string, 'utf-8')\n        return bytes(string, 'utf-8')\n\n    if SUPPORTS_BYTEARRAY:\n        return string\n\n    return bytes(string)\n\ndef to_string(byte_sequence):\n    if isinstance(byte_sequence, bytearray):\n        return byte_sequence.decode(\"utf-8\")\n\n    return byte_sequence\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\__init__.py\nNome: __init__.py\n----------------------------------------\n\"\"\"A client library for the GoCardless Pro API.\"\"\"\n\nfrom .client import Client\n\n__version__ = '1.32.0'\n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\bank_authorisation.py\nNome: bank_authorisation.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass BankAuthorisation(object):\n    \"\"\"A thin wrapper around a bank_authorisation, providing easy access to its\n    attributes.\n\n    Example:\n      bank_authorisation = client.bank_authorisations.get()\n      bank_authorisation.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def authorisation_type(self):\n        return self.attributes.get('authorisation_type')\n  \n\n    @property\n    def authorised_at(self):\n        return self.attributes.get('authorised_at')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def expires_at(self):\n        return self.attributes.get('expires_at')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def last_visited_at(self):\n        return self.attributes.get('last_visited_at')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def redirect_uri(self):\n        return self.attributes.get('redirect_uri')\n  \n\n    @property\n    def url(self):\n        return self.attributes.get('url')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def billing_request(self):\n            return self.attributes.get('billing_request')\n    \n        @property\n        def institution(self):\n            return self.attributes.get('institution')\n    \n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\bank_details_lookup.py\nNome: bank_details_lookup.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass BankDetailsLookup(object):\n    \"\"\"A thin wrapper around a bank_details_lookup, providing easy access to its\n    attributes.\n\n    Example:\n      bank_details_lookup = client.bank_details_lookups.get()\n      bank_details_lookup.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def available_debit_schemes(self):\n        return self.attributes.get('available_debit_schemes')\n  \n\n    @property\n    def bank_name(self):\n        return self.attributes.get('bank_name')\n  \n\n    @property\n    def bic(self):\n        return self.attributes.get('bic')\n  \n\n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\billing_request.py\nNome: billing_request.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass BillingRequest(object):\n    \"\"\"A thin wrapper around a billing_request, providing easy access to its\n    attributes.\n\n    Example:\n      billing_request = client.billing_requests.get()\n      billing_request.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def actions(self):\n        return self.attributes.get('actions')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def fallback_enabled(self):\n        return self.attributes.get('fallback_enabled')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def mandate_request(self):\n        return self.MandateRequest(self.attributes.get('mandate_request'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def payment_request(self):\n        return self.PaymentRequest(self.attributes.get('payment_request'))\n  \n\n    @property\n    def resources(self):\n        return self.Resources(self.attributes.get('resources'))\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def bank_authorisation(self):\n            return self.attributes.get('bank_authorisation')\n    \n        @property\n        def creditor(self):\n            return self.attributes.get('creditor')\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def customer_bank_account(self):\n            return self.attributes.get('customer_bank_account')\n    \n        @property\n        def customer_billing_detail(self):\n            return self.attributes.get('customer_billing_detail')\n    \n        @property\n        def mandate_request(self):\n            return self.attributes.get('mandate_request')\n    \n        @property\n        def mandate_request_mandate(self):\n            return self.attributes.get('mandate_request_mandate')\n    \n        @property\n        def organisation(self):\n            return self.attributes.get('organisation')\n    \n        @property\n        def payment_request(self):\n            return self.attributes.get('payment_request')\n    \n        @property\n        def payment_request_payment(self):\n            return self.attributes.get('payment_request_payment')\n    \n  \n\n  \n    class MandateRequest(object):\n        \"\"\"Wrapper for the response's 'mandate_request' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def currency(self):\n            return self.attributes.get('currency')\n    \n        @property\n        def links(self):\n            return self.attributes.get('links')\n    \n        @property\n        def metadata(self):\n            return self.attributes.get('metadata')\n    \n        @property\n        def scheme(self):\n            return self.attributes.get('scheme')\n    \n        @property\n        def verify(self):\n            return self.attributes.get('verify')\n    \n  \n\n  \n\n  \n    class PaymentRequest(object):\n        \"\"\"Wrapper for the response's 'payment_request' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def amount(self):\n            return self.attributes.get('amount')\n    \n        @property\n        def app_fee(self):\n            return self.attributes.get('app_fee')\n    \n        @property\n        def currency(self):\n            return self.attributes.get('currency')\n    \n        @property\n        def description(self):\n            return self.attributes.get('description')\n    \n        @property\n        def links(self):\n            return self.attributes.get('links')\n    \n        @property\n        def metadata(self):\n            return self.attributes.get('metadata')\n    \n        @property\n        def scheme(self):\n            return self.attributes.get('scheme')\n    \n  \n\n  \n    class Resources(object):\n        \"\"\"Wrapper for the response's 'resources' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def customer_bank_account(self):\n            return self.attributes.get('customer_bank_account')\n    \n        @property\n        def customer_billing_detail(self):\n            return self.attributes.get('customer_billing_detail')\n    \n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\billing_request_flow.py\nNome: billing_request_flow.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass BillingRequestFlow(object):\n    \"\"\"A thin wrapper around a billing_request_flow, providing easy access to its\n    attributes.\n\n    Example:\n      billing_request_flow = client.billing_request_flows.get()\n      billing_request_flow.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def authorisation_url(self):\n        return self.attributes.get('authorisation_url')\n  \n\n    @property\n    def auto_fulfil(self):\n        return self.attributes.get('auto_fulfil')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def exit_uri(self):\n        return self.attributes.get('exit_uri')\n  \n\n    @property\n    def expires_at(self):\n        return self.attributes.get('expires_at')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def lock_bank_account(self):\n        return self.attributes.get('lock_bank_account')\n  \n\n    @property\n    def lock_currency(self):\n        return self.attributes.get('lock_currency')\n  \n\n    @property\n    def lock_customer_details(self):\n        return self.attributes.get('lock_customer_details')\n  \n\n    @property\n    def prefilled_bank_account(self):\n        return self.PrefilledBankAccount(self.attributes.get('prefilled_bank_account'))\n  \n\n    @property\n    def prefilled_customer(self):\n        return self.PrefilledCustomer(self.attributes.get('prefilled_customer'))\n  \n\n    @property\n    def redirect_uri(self):\n        return self.attributes.get('redirect_uri')\n  \n\n    @property\n    def session_token(self):\n        return self.attributes.get('session_token')\n  \n\n    @property\n    def show_redirect_buttons(self):\n        return self.attributes.get('show_redirect_buttons')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def billing_request(self):\n            return self.attributes.get('billing_request')\n    \n  \n\n  \n\n  \n\n  \n\n  \n    class PrefilledBankAccount(object):\n        \"\"\"Wrapper for the response's 'prefilled_bank_account' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def account_type(self):\n            return self.attributes.get('account_type')\n    \n  \n\n  \n    class PrefilledCustomer(object):\n        \"\"\"Wrapper for the response's 'prefilled_customer' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def address_line1(self):\n            return self.attributes.get('address_line1')\n    \n        @property\n        def address_line2(self):\n            return self.attributes.get('address_line2')\n    \n        @property\n        def address_line3(self):\n            return self.attributes.get('address_line3')\n    \n        @property\n        def city(self):\n            return self.attributes.get('city')\n    \n        @property\n        def company_name(self):\n            return self.attributes.get('company_name')\n    \n        @property\n        def country_code(self):\n            return self.attributes.get('country_code')\n    \n        @property\n        def danish_identity_number(self):\n            return self.attributes.get('danish_identity_number')\n    \n        @property\n        def email(self):\n            return self.attributes.get('email')\n    \n        @property\n        def family_name(self):\n            return self.attributes.get('family_name')\n    \n        @property\n        def given_name(self):\n            return self.attributes.get('given_name')\n    \n        @property\n        def language(self):\n            return self.attributes.get('language')\n    \n        @property\n        def postal_code(self):\n            return self.attributes.get('postal_code')\n    \n        @property\n        def region(self):\n            return self.attributes.get('region')\n    \n        @property\n        def swedish_identity_number(self):\n            return self.attributes.get('swedish_identity_number')\n    \n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\billing_request_template.py\nNome: billing_request_template.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass BillingRequestTemplate(object):\n    \"\"\"A thin wrapper around a billing_request_template, providing easy access to its\n    attributes.\n\n    Example:\n      billing_request_template = client.billing_request_templates.get()\n      billing_request_template.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def authorisation_url(self):\n        return self.attributes.get('authorisation_url')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def mandate_request_currency(self):\n        return self.attributes.get('mandate_request_currency')\n  \n\n    @property\n    def mandate_request_metadata(self):\n        return self.attributes.get('mandate_request_metadata')\n  \n\n    @property\n    def mandate_request_scheme(self):\n        return self.attributes.get('mandate_request_scheme')\n  \n\n    @property\n    def mandate_request_verify(self):\n        return self.attributes.get('mandate_request_verify')\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def name(self):\n        return self.attributes.get('name')\n  \n\n    @property\n    def payment_request_amount(self):\n        return self.attributes.get('payment_request_amount')\n  \n\n    @property\n    def payment_request_currency(self):\n        return self.attributes.get('payment_request_currency')\n  \n\n    @property\n    def payment_request_description(self):\n        return self.attributes.get('payment_request_description')\n  \n\n    @property\n    def payment_request_metadata(self):\n        return self.attributes.get('payment_request_metadata')\n  \n\n    @property\n    def payment_request_scheme(self):\n        return self.attributes.get('payment_request_scheme')\n  \n\n    @property\n    def redirect_uri(self):\n        return self.attributes.get('redirect_uri')\n  \n\n    @property\n    def updated_at(self):\n        return self.attributes.get('updated_at')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\block.py\nNome: block.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Block(object):\n    \"\"\"A thin wrapper around a block, providing easy access to its\n    attributes.\n\n    Example:\n      block = client.blocks.get()\n      block.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def active(self):\n        return self.attributes.get('active')\n  \n\n    @property\n    def block_type(self):\n        return self.attributes.get('block_type')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def reason_description(self):\n        return self.attributes.get('reason_description')\n  \n\n    @property\n    def reason_type(self):\n        return self.attributes.get('reason_type')\n  \n\n    @property\n    def resource_reference(self):\n        return self.attributes.get('resource_reference')\n  \n\n    @property\n    def updated_at(self):\n        return self.attributes.get('updated_at')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\creditor.py\nNome: creditor.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Creditor(object):\n    \"\"\"A thin wrapper around a creditor, providing easy access to its\n    attributes.\n\n    Example:\n      creditor = client.creditors.get()\n      creditor.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def address_line1(self):\n        return self.attributes.get('address_line1')\n  \n\n    @property\n    def address_line2(self):\n        return self.attributes.get('address_line2')\n  \n\n    @property\n    def address_line3(self):\n        return self.attributes.get('address_line3')\n  \n\n    @property\n    def can_create_refunds(self):\n        return self.attributes.get('can_create_refunds')\n  \n\n    @property\n    def city(self):\n        return self.attributes.get('city')\n  \n\n    @property\n    def country_code(self):\n        return self.attributes.get('country_code')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def custom_payment_pages_enabled(self):\n        return self.attributes.get('custom_payment_pages_enabled')\n  \n\n    @property\n    def fx_payout_currency(self):\n        return self.attributes.get('fx_payout_currency')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def logo_url(self):\n        return self.attributes.get('logo_url')\n  \n\n    @property\n    def mandate_imports_enabled(self):\n        return self.attributes.get('mandate_imports_enabled')\n  \n\n    @property\n    def merchant_responsible_for_notifications(self):\n        return self.attributes.get('merchant_responsible_for_notifications')\n  \n\n    @property\n    def name(self):\n        return self.attributes.get('name')\n  \n\n    @property\n    def postal_code(self):\n        return self.attributes.get('postal_code')\n  \n\n    @property\n    def region(self):\n        return self.attributes.get('region')\n  \n\n    @property\n    def scheme_identifiers(self):\n        return self.attributes.get('scheme_identifiers')\n  \n\n    @property\n    def verification_status(self):\n        return self.attributes.get('verification_status')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def default_aud_payout_account(self):\n            return self.attributes.get('default_aud_payout_account')\n    \n        @property\n        def default_cad_payout_account(self):\n            return self.attributes.get('default_cad_payout_account')\n    \n        @property\n        def default_dkk_payout_account(self):\n            return self.attributes.get('default_dkk_payout_account')\n    \n        @property\n        def default_eur_payout_account(self):\n            return self.attributes.get('default_eur_payout_account')\n    \n        @property\n        def default_gbp_payout_account(self):\n            return self.attributes.get('default_gbp_payout_account')\n    \n        @property\n        def default_nzd_payout_account(self):\n            return self.attributes.get('default_nzd_payout_account')\n    \n        @property\n        def default_sek_payout_account(self):\n            return self.attributes.get('default_sek_payout_account')\n    \n        @property\n        def default_usd_payout_account(self):\n            return self.attributes.get('default_usd_payout_account')\n    \n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\creditor_bank_account.py\nNome: creditor_bank_account.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass CreditorBankAccount(object):\n    \"\"\"A thin wrapper around a creditor_bank_account, providing easy access to its\n    attributes.\n\n    Example:\n      creditor_bank_account = client.creditor_bank_accounts.get()\n      creditor_bank_account.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def account_holder_name(self):\n        return self.attributes.get('account_holder_name')\n  \n\n    @property\n    def account_number_ending(self):\n        return self.attributes.get('account_number_ending')\n  \n\n    @property\n    def account_type(self):\n        return self.attributes.get('account_type')\n  \n\n    @property\n    def bank_name(self):\n        return self.attributes.get('bank_name')\n  \n\n    @property\n    def country_code(self):\n        return self.attributes.get('country_code')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def currency(self):\n        return self.attributes.get('currency')\n  \n\n    @property\n    def enabled(self):\n        return self.attributes.get('enabled')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def creditor(self):\n            return self.attributes.get('creditor')\n    \n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\currency_exchange_rate.py\nNome: currency_exchange_rate.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass CurrencyExchangeRate(object):\n    \"\"\"A thin wrapper around a currency_exchange_rate, providing easy access to its\n    attributes.\n\n    Example:\n      currency_exchange_rate = client.currency_exchange_rates.get()\n      currency_exchange_rate.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def rate(self):\n        return self.attributes.get('rate')\n  \n\n    @property\n    def source(self):\n        return self.attributes.get('source')\n  \n\n    @property\n    def target(self):\n        return self.attributes.get('target')\n  \n\n    @property\n    def time(self):\n        return self.attributes.get('time')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\customer.py\nNome: customer.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Customer(object):\n    \"\"\"A thin wrapper around a customer, providing easy access to its\n    attributes.\n\n    Example:\n      customer = client.customers.get()\n      customer.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def address_line1(self):\n        return self.attributes.get('address_line1')\n  \n\n    @property\n    def address_line2(self):\n        return self.attributes.get('address_line2')\n  \n\n    @property\n    def address_line3(self):\n        return self.attributes.get('address_line3')\n  \n\n    @property\n    def city(self):\n        return self.attributes.get('city')\n  \n\n    @property\n    def company_name(self):\n        return self.attributes.get('company_name')\n  \n\n    @property\n    def country_code(self):\n        return self.attributes.get('country_code')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def danish_identity_number(self):\n        return self.attributes.get('danish_identity_number')\n  \n\n    @property\n    def email(self):\n        return self.attributes.get('email')\n  \n\n    @property\n    def family_name(self):\n        return self.attributes.get('family_name')\n  \n\n    @property\n    def given_name(self):\n        return self.attributes.get('given_name')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def language(self):\n        return self.attributes.get('language')\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def phone_number(self):\n        return self.attributes.get('phone_number')\n  \n\n    @property\n    def postal_code(self):\n        return self.attributes.get('postal_code')\n  \n\n    @property\n    def region(self):\n        return self.attributes.get('region')\n  \n\n    @property\n    def swedish_identity_number(self):\n        return self.attributes.get('swedish_identity_number')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\customer_bank_account.py\nNome: customer_bank_account.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass CustomerBankAccount(object):\n    \"\"\"A thin wrapper around a customer_bank_account, providing easy access to its\n    attributes.\n\n    Example:\n      customer_bank_account = client.customer_bank_accounts.get()\n      customer_bank_account.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def account_holder_name(self):\n        return self.attributes.get('account_holder_name')\n  \n\n    @property\n    def account_number_ending(self):\n        return self.attributes.get('account_number_ending')\n  \n\n    @property\n    def account_type(self):\n        return self.attributes.get('account_type')\n  \n\n    @property\n    def bank_name(self):\n        return self.attributes.get('bank_name')\n  \n\n    @property\n    def country_code(self):\n        return self.attributes.get('country_code')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def currency(self):\n        return self.attributes.get('currency')\n  \n\n    @property\n    def enabled(self):\n        return self.attributes.get('enabled')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\customer_notification.py\nNome: customer_notification.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass CustomerNotification(object):\n    \"\"\"A thin wrapper around a customer_notification, providing easy access to its\n    attributes.\n\n    Example:\n      customer_notification = client.customer_notifications.get()\n      customer_notification.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def action_taken(self):\n        return self.attributes.get('action_taken')\n  \n\n    @property\n    def action_taken_at(self):\n        return self.attributes.get('action_taken_at')\n  \n\n    @property\n    def action_taken_by(self):\n        return self.attributes.get('action_taken_by')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def type(self):\n        return self.attributes.get('type')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def event(self):\n            return self.attributes.get('event')\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n        @property\n        def payment(self):\n            return self.attributes.get('payment')\n    \n        @property\n        def refund(self):\n            return self.attributes.get('refund')\n    \n        @property\n        def subscription(self):\n            return self.attributes.get('subscription')\n    \n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\event.py\nNome: event.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Event(object):\n    \"\"\"A thin wrapper around a event, providing easy access to its\n    attributes.\n\n    Example:\n      event = client.events.get()\n      event.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def action(self):\n        return self.attributes.get('action')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def customer_notifications(self):\n        return self.attributes.get('customer_notifications')\n  \n\n    @property\n    def details(self):\n        return self.Details(self.attributes.get('details'))\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def resource_type(self):\n        return self.attributes.get('resource_type')\n  \n\n\n  \n\n  \n\n  \n\n  \n    class Details(object):\n        \"\"\"Wrapper for the response's 'details' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def bank_account_id(self):\n            return self.attributes.get('bank_account_id')\n    \n        @property\n        def cause(self):\n            return self.attributes.get('cause')\n    \n        @property\n        def currency(self):\n            return self.attributes.get('currency')\n    \n        @property\n        def description(self):\n            return self.attributes.get('description')\n    \n        @property\n        def not_retried_reason(self):\n            return self.attributes.get('not_retried_reason')\n    \n        @property\n        def origin(self):\n            return self.attributes.get('origin')\n    \n        @property\n        def _property(self):\n            return self.attributes.get('property')\n    \n        @property\n        def reason_code(self):\n            return self.attributes.get('reason_code')\n    \n        @property\n        def scheme(self):\n            return self.attributes.get('scheme')\n    \n        @property\n        def will_attempt_retry(self):\n            return self.attributes.get('will_attempt_retry')\n    \n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def bank_authorisation(self):\n            return self.attributes.get('bank_authorisation')\n    \n        @property\n        def billing_request(self):\n            return self.attributes.get('billing_request')\n    \n        @property\n        def billing_request_flow(self):\n            return self.attributes.get('billing_request_flow')\n    \n        @property\n        def creditor(self):\n            return self.attributes.get('creditor')\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def customer_bank_account(self):\n            return self.attributes.get('customer_bank_account')\n    \n        @property\n        def instalment_schedule(self):\n            return self.attributes.get('instalment_schedule')\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n        @property\n        def mandate_request_mandate(self):\n            return self.attributes.get('mandate_request_mandate')\n    \n        @property\n        def new_customer_bank_account(self):\n            return self.attributes.get('new_customer_bank_account')\n    \n        @property\n        def new_mandate(self):\n            return self.attributes.get('new_mandate')\n    \n        @property\n        def organisation(self):\n            return self.attributes.get('organisation')\n    \n        @property\n        def parent_event(self):\n            return self.attributes.get('parent_event')\n    \n        @property\n        def payer_authorisation(self):\n            return self.attributes.get('payer_authorisation')\n    \n        @property\n        def payment(self):\n            return self.attributes.get('payment')\n    \n        @property\n        def payment_request_payment(self):\n            return self.attributes.get('payment_request_payment')\n    \n        @property\n        def payout(self):\n            return self.attributes.get('payout')\n    \n        @property\n        def previous_customer_bank_account(self):\n            return self.attributes.get('previous_customer_bank_account')\n    \n        @property\n        def refund(self):\n            return self.attributes.get('refund')\n    \n        @property\n        def subscription(self):\n            return self.attributes.get('subscription')\n    \n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\instalment_schedule.py\nNome: instalment_schedule.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass InstalmentSchedule(object):\n    \"\"\"A thin wrapper around a instalment_schedule, providing easy access to its\n    attributes.\n\n    Example:\n      instalment_schedule = client.instalment_schedules.get()\n      instalment_schedule.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def currency(self):\n        return self.attributes.get('currency')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def name(self):\n        return self.attributes.get('name')\n  \n\n    @property\n    def payment_errors(self):\n        return self.attributes.get('payment_errors')\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n    @property\n    def total_amount(self):\n        return self.attributes.get('total_amount')\n  \n\n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n        @property\n        def payments(self):\n            return self.attributes.get('payments')\n    \n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\institution.py\nNome: institution.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Institution(object):\n    \"\"\"A thin wrapper around a institution, providing easy access to its\n    attributes.\n\n    Example:\n      institution = client.institutions.get()\n      institution.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def bank_redirect(self):\n        return self.attributes.get('bank_redirect')\n  \n\n    @property\n    def country_code(self):\n        return self.attributes.get('country_code')\n  \n\n    @property\n    def icon_url(self):\n        return self.attributes.get('icon_url')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def logo_url(self):\n        return self.attributes.get('logo_url')\n  \n\n    @property\n    def name(self):\n        return self.attributes.get('name')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\mandate.py\nNome: mandate.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Mandate(object):\n    \"\"\"A thin wrapper around a mandate, providing easy access to its\n    attributes.\n\n    Example:\n      mandate = client.mandates.get()\n      mandate.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def next_possible_charge_date(self):\n        return self.attributes.get('next_possible_charge_date')\n  \n\n    @property\n    def payments_require_approval(self):\n        return self.attributes.get('payments_require_approval')\n  \n\n    @property\n    def reference(self):\n        return self.attributes.get('reference')\n  \n\n    @property\n    def scheme(self):\n        return self.attributes.get('scheme')\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def creditor(self):\n            return self.attributes.get('creditor')\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def customer_bank_account(self):\n            return self.attributes.get('customer_bank_account')\n    \n        @property\n        def new_mandate(self):\n            return self.attributes.get('new_mandate')\n    \n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\mandate_import.py\nNome: mandate_import.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass MandateImport(object):\n    \"\"\"A thin wrapper around a mandate_import, providing easy access to its\n    attributes.\n\n    Example:\n      mandate_import = client.mandate_imports.get()\n      mandate_import.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def scheme(self):\n        return self.attributes.get('scheme')\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\mandate_import_entry.py\nNome: mandate_import_entry.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass MandateImportEntry(object):\n    \"\"\"A thin wrapper around a mandate_import_entry, providing easy access to its\n    attributes.\n\n    Example:\n      mandate_import_entry = client.mandate_import_entries.get()\n      mandate_import_entry.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def record_identifier(self):\n        return self.attributes.get('record_identifier')\n  \n\n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def customer_bank_account(self):\n            return self.attributes.get('customer_bank_account')\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n        @property\n        def mandate_import(self):\n            return self.attributes.get('mandate_import')\n    \n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\mandate_pdf.py\nNome: mandate_pdf.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass MandatePdf(object):\n    \"\"\"A thin wrapper around a mandate_pdf, providing easy access to its\n    attributes.\n\n    Example:\n      mandate_pdf = client.mandate_pdfs.get()\n      mandate_pdf.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def expires_at(self):\n        return self.attributes.get('expires_at')\n  \n\n    @property\n    def url(self):\n        return self.attributes.get('url')\n  \n\n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\payer_authorisation.py\nNome: payer_authorisation.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass PayerAuthorisation(object):\n    \"\"\"A thin wrapper around a payer_authorisation, providing easy access to its\n    attributes.\n\n    Example:\n      payer_authorisation = client.payer_authorisations.get()\n      payer_authorisation.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def bank_account(self):\n        return self.BankAccount(self.attributes.get('bank_account'))\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def customer(self):\n        return self.Customer(self.attributes.get('customer'))\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def incomplete_fields(self):\n        return self.attributes.get('incomplete_fields')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def mandate(self):\n        return self.Mandate(self.attributes.get('mandate'))\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n\n  \n    class BankAccount(object):\n        \"\"\"Wrapper for the response's 'bank_account' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def account_holder_name(self):\n            return self.attributes.get('account_holder_name')\n    \n        @property\n        def account_number(self):\n            return self.attributes.get('account_number')\n    \n        @property\n        def account_number_ending(self):\n            return self.attributes.get('account_number_ending')\n    \n        @property\n        def account_number_suffix(self):\n            return self.attributes.get('account_number_suffix')\n    \n        @property\n        def account_type(self):\n            return self.attributes.get('account_type')\n    \n        @property\n        def bank_code(self):\n            return self.attributes.get('bank_code')\n    \n        @property\n        def branch_code(self):\n            return self.attributes.get('branch_code')\n    \n        @property\n        def country_code(self):\n            return self.attributes.get('country_code')\n    \n        @property\n        def currency(self):\n            return self.attributes.get('currency')\n    \n        @property\n        def iban(self):\n            return self.attributes.get('iban')\n    \n        @property\n        def metadata(self):\n            return self.attributes.get('metadata')\n    \n  \n\n  \n\n  \n    class Customer(object):\n        \"\"\"Wrapper for the response's 'customer' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def address_line1(self):\n            return self.attributes.get('address_line1')\n    \n        @property\n        def address_line2(self):\n            return self.attributes.get('address_line2')\n    \n        @property\n        def address_line3(self):\n            return self.attributes.get('address_line3')\n    \n        @property\n        def city(self):\n            return self.attributes.get('city')\n    \n        @property\n        def company_name(self):\n            return self.attributes.get('company_name')\n    \n        @property\n        def country_code(self):\n            return self.attributes.get('country_code')\n    \n        @property\n        def danish_identity_number(self):\n            return self.attributes.get('danish_identity_number')\n    \n        @property\n        def email(self):\n            return self.attributes.get('email')\n    \n        @property\n        def family_name(self):\n            return self.attributes.get('family_name')\n    \n        @property\n        def given_name(self):\n            return self.attributes.get('given_name')\n    \n        @property\n        def locale(self):\n            return self.attributes.get('locale')\n    \n        @property\n        def metadata(self):\n            return self.attributes.get('metadata')\n    \n        @property\n        def postal_code(self):\n            return self.attributes.get('postal_code')\n    \n        @property\n        def region(self):\n            return self.attributes.get('region')\n    \n        @property\n        def swedish_identity_number(self):\n            return self.attributes.get('swedish_identity_number')\n    \n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def bank_account(self):\n            return self.attributes.get('bank_account')\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n  \n\n  \n    class Mandate(object):\n        \"\"\"Wrapper for the response's 'mandate' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def metadata(self):\n            return self.attributes.get('metadata')\n    \n        @property\n        def payer_ip_address(self):\n            return self.attributes.get('payer_ip_address')\n    \n        @property\n        def reference(self):\n            return self.attributes.get('reference')\n    \n        @property\n        def scheme(self):\n            return self.attributes.get('scheme')\n    \n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\payment.py\nNome: payment.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Payment(object):\n    \"\"\"A thin wrapper around a payment, providing easy access to its\n    attributes.\n\n    Example:\n      payment = client.payments.get()\n      payment.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def amount(self):\n        return self.attributes.get('amount')\n  \n\n    @property\n    def amount_refunded(self):\n        return self.attributes.get('amount_refunded')\n  \n\n    @property\n    def charge_date(self):\n        return self.attributes.get('charge_date')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def currency(self):\n        return self.attributes.get('currency')\n  \n\n    @property\n    def description(self):\n        return self.attributes.get('description')\n  \n\n    @property\n    def fx(self):\n        return self.Fx(self.attributes.get('fx'))\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def reference(self):\n        return self.attributes.get('reference')\n  \n\n    @property\n    def retry_if_possible(self):\n        return self.attributes.get('retry_if_possible')\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Fx(object):\n        \"\"\"Wrapper for the response's 'fx' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def estimated_exchange_rate(self):\n            return self.attributes.get('estimated_exchange_rate')\n    \n        @property\n        def exchange_rate(self):\n            return self.attributes.get('exchange_rate')\n    \n        @property\n        def fx_amount(self):\n            return self.attributes.get('fx_amount')\n    \n        @property\n        def fx_currency(self):\n            return self.attributes.get('fx_currency')\n    \n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def creditor(self):\n            return self.attributes.get('creditor')\n    \n        @property\n        def instalment_schedule(self):\n            return self.attributes.get('instalment_schedule')\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n        @property\n        def payout(self):\n            return self.attributes.get('payout')\n    \n        @property\n        def subscription(self):\n            return self.attributes.get('subscription')\n    \n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\payout.py\nNome: payout.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Payout(object):\n    \"\"\"A thin wrapper around a payout, providing easy access to its\n    attributes.\n\n    Example:\n      payout = client.payouts.get()\n      payout.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def amount(self):\n        return self.attributes.get('amount')\n  \n\n    @property\n    def arrival_date(self):\n        return self.attributes.get('arrival_date')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def currency(self):\n        return self.attributes.get('currency')\n  \n\n    @property\n    def deducted_fees(self):\n        return self.attributes.get('deducted_fees')\n  \n\n    @property\n    def fx(self):\n        return self.Fx(self.attributes.get('fx'))\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def payout_type(self):\n        return self.attributes.get('payout_type')\n  \n\n    @property\n    def reference(self):\n        return self.attributes.get('reference')\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n    @property\n    def tax_currency(self):\n        return self.attributes.get('tax_currency')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Fx(object):\n        \"\"\"Wrapper for the response's 'fx' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def estimated_exchange_rate(self):\n            return self.attributes.get('estimated_exchange_rate')\n    \n        @property\n        def exchange_rate(self):\n            return self.attributes.get('exchange_rate')\n    \n        @property\n        def fx_amount(self):\n            return self.attributes.get('fx_amount')\n    \n        @property\n        def fx_currency(self):\n            return self.attributes.get('fx_currency')\n    \n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def creditor(self):\n            return self.attributes.get('creditor')\n    \n        @property\n        def creditor_bank_account(self):\n            return self.attributes.get('creditor_bank_account')\n    \n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\payout_item.py\nNome: payout_item.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass PayoutItem(object):\n    \"\"\"A thin wrapper around a payout_item, providing easy access to its\n    attributes.\n\n    Example:\n      payout_item = client.payout_items.get()\n      payout_item.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def amount(self):\n        return self.attributes.get('amount')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def taxes(self):\n        return self.attributes.get('taxes')\n  \n\n    @property\n    def type(self):\n        return self.attributes.get('type')\n  \n\n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n        @property\n        def payment(self):\n            return self.attributes.get('payment')\n    \n        @property\n        def refund(self):\n            return self.attributes.get('refund')\n    \n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\redirect_flow.py\nNome: redirect_flow.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass RedirectFlow(object):\n    \"\"\"A thin wrapper around a redirect_flow, providing easy access to its\n    attributes.\n\n    Example:\n      redirect_flow = client.redirect_flows.get()\n      redirect_flow.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def confirmation_url(self):\n        return self.attributes.get('confirmation_url')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def description(self):\n        return self.attributes.get('description')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def mandate_reference(self):\n        return self.attributes.get('mandate_reference')\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def redirect_url(self):\n        return self.attributes.get('redirect_url')\n  \n\n    @property\n    def scheme(self):\n        return self.attributes.get('scheme')\n  \n\n    @property\n    def session_token(self):\n        return self.attributes.get('session_token')\n  \n\n    @property\n    def success_redirect_url(self):\n        return self.attributes.get('success_redirect_url')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def billing_request(self):\n            return self.attributes.get('billing_request')\n    \n        @property\n        def creditor(self):\n            return self.attributes.get('creditor')\n    \n        @property\n        def customer(self):\n            return self.attributes.get('customer')\n    \n        @property\n        def customer_bank_account(self):\n            return self.attributes.get('customer_bank_account')\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\refund.py\nNome: refund.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Refund(object):\n    \"\"\"A thin wrapper around a refund, providing easy access to its\n    attributes.\n\n    Example:\n      refund = client.refunds.get()\n      refund.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def amount(self):\n        return self.attributes.get('amount')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def currency(self):\n        return self.attributes.get('currency')\n  \n\n    @property\n    def fx(self):\n        return self.Fx(self.attributes.get('fx'))\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def reference(self):\n        return self.attributes.get('reference')\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n\n  \n\n  \n\n  \n\n  \n    class Fx(object):\n        \"\"\"Wrapper for the response's 'fx' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def estimated_exchange_rate(self):\n            return self.attributes.get('estimated_exchange_rate')\n    \n        @property\n        def exchange_rate(self):\n            return self.attributes.get('exchange_rate')\n    \n        @property\n        def fx_amount(self):\n            return self.attributes.get('fx_amount')\n    \n        @property\n        def fx_currency(self):\n            return self.attributes.get('fx_currency')\n    \n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n        @property\n        def payment(self):\n            return self.attributes.get('payment')\n    \n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\scenario_simulator.py\nNome: scenario_simulator.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass ScenarioSimulator(object):\n    \"\"\"A thin wrapper around a scenario_simulator, providing easy access to its\n    attributes.\n\n    Example:\n      scenario_simulator = client.scenario_simulators.get()\n      scenario_simulator.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\subscription.py\nNome: subscription.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Subscription(object):\n    \"\"\"A thin wrapper around a subscription, providing easy access to its\n    attributes.\n\n    Example:\n      subscription = client.subscriptions.get()\n      subscription.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def amount(self):\n        return self.attributes.get('amount')\n  \n\n    @property\n    def app_fee(self):\n        return self.attributes.get('app_fee')\n  \n\n    @property\n    def count(self):\n        return self.attributes.get('count')\n  \n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def currency(self):\n        return self.attributes.get('currency')\n  \n\n    @property\n    def day_of_month(self):\n        return self.attributes.get('day_of_month')\n  \n\n    @property\n    def earliest_charge_date_after_resume(self):\n        return self.attributes.get('earliest_charge_date_after_resume')\n  \n\n    @property\n    def end_date(self):\n        return self.attributes.get('end_date')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def interval(self):\n        return self.attributes.get('interval')\n  \n\n    @property\n    def interval_unit(self):\n        return self.attributes.get('interval_unit')\n  \n\n    @property\n    def links(self):\n        return self.Links(self.attributes.get('links'))\n  \n\n    @property\n    def metadata(self):\n        return self.attributes.get('metadata')\n  \n\n    @property\n    def month(self):\n        return self.attributes.get('month')\n  \n\n    @property\n    def name(self):\n        return self.attributes.get('name')\n  \n\n    @property\n    def payment_reference(self):\n        return self.attributes.get('payment_reference')\n  \n\n    @property\n    def retry_if_possible(self):\n        return self.attributes.get('retry_if_possible')\n  \n\n    @property\n    def start_date(self):\n        return self.attributes.get('start_date')\n  \n\n    @property\n    def status(self):\n        return self.attributes.get('status')\n  \n\n    @property\n    def upcoming_payments(self):\n        return self.attributes.get('upcoming_payments')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n    class Links(object):\n        \"\"\"Wrapper for the response's 'links' attribute.\"\"\"\n\n        def __init__(self, attributes):\n            self.attributes = attributes\n    \n        @property\n        def mandate(self):\n            return self.attributes.get('mandate')\n    \n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\tax_rate.py\nNome: tax_rate.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass TaxRate(object):\n    \"\"\"A thin wrapper around a tax_rate, providing easy access to its\n    attributes.\n\n    Example:\n      tax_rate = client.tax_rates.get()\n      tax_rate.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def end_date(self):\n        return self.attributes.get('end_date')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def jurisdiction(self):\n        return self.attributes.get('jurisdiction')\n  \n\n    @property\n    def percentage(self):\n        return self.attributes.get('percentage')\n  \n\n    @property\n    def start_date(self):\n        return self.attributes.get('start_date')\n  \n\n    @property\n    def type(self):\n        return self.attributes.get('type')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\webhook.py\nNome: webhook.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nclass Webhook(object):\n    \"\"\"A thin wrapper around a webhook, providing easy access to its\n    attributes.\n\n    Example:\n      webhook = client.webhooks.get()\n      webhook.id\n    \"\"\"\n\n    def __init__(self, attributes, api_response):\n        self.attributes = attributes\n        self.api_response = api_response\n\n    @property\n    def created_at(self):\n        return self.attributes.get('created_at')\n  \n\n    @property\n    def id(self):\n        return self.attributes.get('id')\n  \n\n    @property\n    def is_test(self):\n        return self.attributes.get('is_test')\n  \n\n    @property\n    def request_body(self):\n        return self.attributes.get('request_body')\n  \n\n    @property\n    def request_headers(self):\n        return self.attributes.get('request_headers')\n  \n\n    @property\n    def response_body(self):\n        return self.attributes.get('response_body')\n  \n\n    @property\n    def response_body_truncated(self):\n        return self.attributes.get('response_body_truncated')\n  \n\n    @property\n    def response_code(self):\n        return self.attributes.get('response_code')\n  \n\n    @property\n    def response_headers(self):\n        return self.attributes.get('response_headers')\n  \n\n    @property\n    def response_headers_content_truncated(self):\n        return self.attributes.get('response_headers_content_truncated')\n  \n\n    @property\n    def response_headers_count_truncated(self):\n        return self.attributes.get('response_headers_count_truncated')\n  \n\n    @property\n    def successful(self):\n        return self.attributes.get('successful')\n  \n\n    @property\n    def url(self):\n        return self.attributes.get('url')\n  \n\n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n  \n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\resources\\__init__.py\nNome: __init__.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom .bank_authorisation import BankAuthorisation\n\nfrom .bank_details_lookup import BankDetailsLookup\n\nfrom .billing_request import BillingRequest\n\nfrom .billing_request_flow import BillingRequestFlow\n\nfrom .billing_request_template import BillingRequestTemplate\n\nfrom .block import Block\n\nfrom .creditor import Creditor\n\nfrom .creditor_bank_account import CreditorBankAccount\n\nfrom .currency_exchange_rate import CurrencyExchangeRate\n\nfrom .customer import Customer\n\nfrom .customer_bank_account import CustomerBankAccount\n\nfrom .customer_notification import CustomerNotification\n\nfrom .event import Event\n\nfrom .instalment_schedule import InstalmentSchedule\n\nfrom .institution import Institution\n\nfrom .mandate import Mandate\n\nfrom .mandate_import import MandateImport\n\nfrom .mandate_import_entry import MandateImportEntry\n\nfrom .mandate_pdf import MandatePdf\n\nfrom .payer_authorisation import PayerAuthorisation\n\nfrom .payment import Payment\n\nfrom .payout import Payout\n\nfrom .payout_item import PayoutItem\n\nfrom .redirect_flow import RedirectFlow\n\nfrom .refund import Refund\n\nfrom .scenario_simulator import ScenarioSimulator\n\nfrom .subscription import Subscription\n\nfrom .tax_rate import TaxRate\n\nfrom .webhook import Webhook\n\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\bank_authorisations_service.py\nNome: bank_authorisations_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass BankAuthorisationsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the bank_authorisations\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.BankAuthorisation\n    RESOURCE_NAME = 'bank_authorisations'\n\n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a Bank Authorisation..\n\n        Fetches a bank authorisation\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BAU\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              BankAuthorisation\n        \"\"\"\n        path = self._sub_url_params('/bank_authorisations/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a Bank Authorisation.\n\n        Create a Bank Authorisation.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              BankAuthorisation\n        \"\"\"\n        path = '/bank_authorisations'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\bank_details_lookups_service.py\nNome: bank_details_lookups_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass BankDetailsLookupsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the bank_details_lookups\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.BankDetailsLookup\n    RESOURCE_NAME = 'bank_details_lookups'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Perform a bank details lookup.\n\n        Performs a bank details lookup. As part of the lookup, a modulus check\n        and\n        reachability check are performed.\n        \n        If your request returns an [error](#api-usage-errors) or the\n        `available_debit_schemes`\n        attribute is an empty array, you will not be able to collect payments\n        from the\n        specified bank account. GoCardless may be able to collect payments from\n        an account\n        even if no `bic` is returned.\n        \n        Bank account details may be supplied using [local\n        details](#appendix-local-bank-details) or an IBAN.\n        \n        _ACH scheme_ For compliance reasons, an extra validation step is done\n        using\n        a third-party provider to make sure the customer's bank account can\n        accept\n        Direct Debit. If a bank account is discovered to be closed or invalid,\n        the\n        customer is requested to adjust the account number/routing number and\n        succeed in this check to continue with the flow.\n        \n        _Note:_ Usage of this endpoint is monitored. If your organisation\n        relies on GoCardless for\n        modulus or reachability checking but not for payment collection, please\n        get in touch.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              BankDetailsLookup\n        \"\"\"\n        path = '/bank_details_lookups'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\base_service.py\nNome: base_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nimport re\nimport time\nfrom requests import Timeout, ConnectionError\nfrom uuid import uuid4\n\nfrom .. import list_response\nfrom ..api_response import ApiResponse\nfrom ..errors import MalformedResponseError\n\nclass BaseService(object):\n    \"\"\"Base class for API service classes.\"\"\"\n    def __init__(self, api_client, max_network_retries=3, retry_delay_in_seconds=0.5, raise_on_idempotency_conflict=False):\n        self._api_client = api_client\n        self.max_network_retries = max_network_retries\n        self.retry_delay_in_seconds = retry_delay_in_seconds\n        self.raise_on_idempotency_conflict = raise_on_idempotency_conflict\n\n    def _perform_request(self, method, path, params, headers=None, retry_failures=False):\n        if method == 'POST':\n            headers = self._inject_idempotency_key(headers)\n\n        if retry_failures:\n            for retries_left in range(self.max_network_retries-1, -1, -1):\n                try:\n                    return self._attempt_request(method, path, params, headers)\n                except (Timeout, ConnectionError, MalformedResponseError) as err:\n                    if retries_left > 0:\n                        time.sleep(self.retry_delay_in_seconds)\n                    else:\n                        raise err\n        else:\n            return self._attempt_request(method, path, params, headers)\n\n    def _attempt_request(self, method, path, params, headers):\n        if method == 'GET':\n            return self._api_client.get(path, params=params, headers=headers)\n\n        if method == 'POST':\n            return self._api_client.post(path, body=params, headers=headers)\n\n        if method == 'PUT':\n            return self._api_client.put(path, body=params, headers=headers)\n\n        if method == 'DELETE':\n            return self._api_client.delete(path, body=params, headers=headers)\n\n        raise ValueError('Invalid method \"{}\"'.format(method))\n\n\n    def _inject_idempotency_key(self, headers):\n        headers = headers or {}\n        if 'Idempotency-Key' not in headers:\n            headers['Idempotency-Key'] = str(uuid4())\n\n        return headers\n\n    def _envelope_key(self):\n        return type(self).RESOURCE_NAME\n\n    def _resource_for(self, response):\n        api_response = ApiResponse(response)\n\n        data = api_response.body[self._envelope_key()]\n        klass = type(self).RESOURCE_CLASS\n        if isinstance(data, dict):\n            return klass(data, api_response)\n        else:\n            records = [klass(item, api_response) for item in data]\n            return list_response.ListResponse(records, api_response)\n\n    def _sub_url_params(self, url, params):\n        return re.sub(r':(\\w+)', lambda match: params[match.group(1)], url)\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\billing_requests_service.py\nNome: billing_requests_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass BillingRequestsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the billing_requests\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.BillingRequest\n    RESOURCE_NAME = 'billing_requests'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List Billing Requests.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        billing requests.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of BillingRequest instances\n        \"\"\"\n        path = '/billing_requests'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a Billing Request.\n\n        \n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = '/billing_requests'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single Billing Request.\n\n        Fetches a billing request\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def collect_customer_details(self,identity,params=None, headers=None):\n        \"\"\"Collect customer details for a Billing Request.\n\n        If the billing request has a pending\n        <code>collect_customer_details</code>\n        action, this endpoint can be used to collect the details in order to\n        complete it.\n        \n        The endpoint takes the same payload as Customers, but checks that the\n        customer fields are populated correctly for the billing request scheme.\n        \n        Whatever is provided to this endpoint is used to update the referenced\n        customer, and will take effect immediately after the request is\n        successful.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/collect_customer_details', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def collect_bank_account(self,identity,params=None, headers=None):\n        \"\"\"Collect bank account details for a Billing Request.\n\n        If the billing request has a pending\n        <code>collect_bank_account</code> action, this endpoint can be\n        used to collect the details in order to complete it.\n        \n        The endpoint takes the same payload as Customer Bank Accounts, but\n        check\n        the bank account is valid for the billing request scheme before\n        creating\n        and attaching it.\n        \n        _ACH scheme_ For compliance reasons, an extra validation step is done\n        using\n        a third-party provider to make sure the customer's bank account can\n        accept\n        Direct Debit. If a bank account is discovered to be closed or invalid,\n        the\n        customer is requested to adjust the account number/routing number and\n        succeed in this check to continue with the flow.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/collect_bank_account', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def fulfil(self,identity,params=None, headers=None):\n        \"\"\"Fulfil a Billing Request.\n\n        If a billing request is ready to be fulfilled, call this endpoint to\n        cause\n        it to fulfil, executing the payment.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/fulfil', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def choose_currency(self,identity,params=None, headers=None):\n        \"\"\"Change currency for a Billing Request.\n\n        This will allow for the updating of the currency and subsequently the\n        scheme if needed for a billing request\n        this will only be available for mandate only flows, it will not support\n        payments requests or plans\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/choose_currency', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def confirm_payer_details(self,identity,params=None, headers=None):\n        \"\"\"Confirm the customer and bank account details.\n\n        This is needed when you have a mandate request. As a scheme compliance\n        rule we are required to\n        allow the payer to crosscheck the details entered by them and confirm\n        it.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/confirm_payer_details', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def cancel(self,identity,params=None, headers=None):\n        \"\"\"Cancel a Billing Request.\n\n        Immediately cancels a billing request, causing all billing request\n        flows\n        to expire.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/cancel', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def notify(self,identity,params=None, headers=None):\n        \"\"\"Notify the customer of a Billing Request.\n\n        Notifies the customer linked to the billing request, asking them to\n        authorise it.\n        Currently, the customer can only be notified by email.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/notify', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def fallback(self,identity,params=None, headers=None):\n        \"\"\"Trigger fallback for a Billing Request.\n\n        Triggers a fallback from the open-banking flow to direct debit. Note,\n        the billing request must have fallback enabled.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequest\n        \"\"\"\n        path = self._sub_url_params('/billing_requests/:identity/actions/fallback', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\billing_request_flows_service.py\nNome: billing_request_flows_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass BillingRequestFlowsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the billing_request_flows\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.BillingRequestFlow\n    RESOURCE_NAME = 'billing_request_flows'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a Billing Request Flow.\n\n        Creates a new billing request flow.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequestFlow\n        \"\"\"\n        path = '/billing_request_flows'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def initialise(self,identity,params=None, headers=None):\n        \"\"\"Initialise a Billing Request Flow.\n\n        Returns the flow having generated a fresh session token which can be\n        used to power\n        integrations that manipulate the flow.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRF\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequestFlow\n        \"\"\"\n        path = self._sub_url_params('/billing_request_flows/:identity/actions/initialise', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\billing_request_templates_service.py\nNome: billing_request_templates_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass BillingRequestTemplatesService(base_service.BaseService):\n    \"\"\"Service class that provides access to the billing_request_templates\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.BillingRequestTemplate\n    RESOURCE_NAME = 'billing_request_templates'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List Billing Request Templates.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        Billing Request Templates.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of BillingRequestTemplate instances\n        \"\"\"\n        path = '/billing_request_templates'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single Billing Request Template.\n\n        Fetches a Billing Request Template\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRT\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              BillingRequestTemplate\n        \"\"\"\n        path = self._sub_url_params('/billing_request_templates/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a Billing Request Template.\n\n        \n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequestTemplate\n        \"\"\"\n        path = '/billing_request_templates'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a Billing Request Template.\n\n        Updates a Billing Request Template, which will affect all future\n        Billing Requests created by this template.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BRQ\".\n              params (dict, optional): Request body.\n\n        Returns:\n              BillingRequestTemplate\n        \"\"\"\n        path = self._sub_url_params('/billing_request_templates/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\blocks_service.py\nNome: blocks_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass BlocksService(base_service.BaseService):\n    \"\"\"Service class that provides access to the blocks\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Block\n    RESOURCE_NAME = 'blocks'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a block.\n\n        Creates a new Block of a given type. By default it will be active.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              Block\n        \"\"\"\n        path = '/blocks'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single block.\n\n        Retrieves the details of an existing block.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BLC\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Block\n        \"\"\"\n        path = self._sub_url_params('/blocks/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List multiple blocks.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        blocks.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Block instances\n        \"\"\"\n        path = '/blocks'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def disable(self,identity,params=None, headers=None):\n        \"\"\"Disable a block.\n\n        Disables a block so that it no longer will prevent mandate creation.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BLC\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Block\n        \"\"\"\n        path = self._sub_url_params('/blocks/:identity/actions/disable', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def enable(self,identity,params=None, headers=None):\n        \"\"\"Enable a block.\n\n        Enables a previously disabled block so that it will prevent mandate\n        creation\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BLC\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Block\n        \"\"\"\n        path = self._sub_url_params('/blocks/:identity/actions/enable', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def block_by_ref(self,params=None, headers=None):\n        \"\"\"Create blocks by reference.\n\n        Creates new blocks for a given reference. By default blocks will be\n        active.\n        Returns 201 if at least one block was created. Returns 200 if there\n        were no new\n        blocks created.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              ListResponse of Block instances\n        \"\"\"\n        path = '/block_by_ref'\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\creditors_service.py\nNome: creditors_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass CreditorsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the creditors\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Creditor\n    RESOURCE_NAME = 'creditors'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a creditor.\n\n        Creates a new creditor.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              Creditor\n        \"\"\"\n        path = '/creditors'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List creditors.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        creditors.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Creditor instances\n        \"\"\"\n        path = '/creditors'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single creditor.\n\n        Retrieves the details of an existing creditor.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"CR\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Creditor\n        \"\"\"\n        path = self._sub_url_params('/creditors/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a creditor.\n\n        Updates a creditor object. Supports all of the fields supported when\n        creating a creditor.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"CR\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Creditor\n        \"\"\"\n        path = self._sub_url_params('/creditors/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\creditor_bank_accounts_service.py\nNome: creditor_bank_accounts_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass CreditorBankAccountsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the creditor_bank_accounts\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.CreditorBankAccount\n    RESOURCE_NAME = 'creditor_bank_accounts'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a creditor bank account.\n\n        Creates a new creditor bank account object.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              CreditorBankAccount\n        \"\"\"\n        path = '/creditor_bank_accounts'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List creditor bank accounts.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        creditor bank accounts.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of CreditorBankAccount instances\n        \"\"\"\n        path = '/creditor_bank_accounts'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single creditor bank account.\n\n        Retrieves the details of an existing creditor bank account.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BA\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              CreditorBankAccount\n        \"\"\"\n        path = self._sub_url_params('/creditor_bank_accounts/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def disable(self,identity,params=None, headers=None):\n        \"\"\"Disable a creditor bank account.\n\n        Immediately disables the bank account, no money can be paid out to a\n        disabled account.\n        \n        This will return a `disable_failed` error if the bank account has\n        already been disabled.\n        \n        A disabled bank account can be re-enabled by creating a new bank\n        account resource with the same details.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BA\".\n              params (dict, optional): Request body.\n\n        Returns:\n              CreditorBankAccount\n        \"\"\"\n        path = self._sub_url_params('/creditor_bank_accounts/:identity/actions/disable', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\currency_exchange_rates_service.py\nNome: currency_exchange_rates_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass CurrencyExchangeRatesService(base_service.BaseService):\n    \"\"\"Service class that provides access to the currency_exchange_rates\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.CurrencyExchangeRate\n    RESOURCE_NAME = 'currency_exchange_rates'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List exchange rates.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of all\n        exchange rates.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of CurrencyExchangeRate instances\n        \"\"\"\n        path = '/currency_exchange_rates'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\customers_service.py\nNome: customers_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass CustomersService(base_service.BaseService):\n    \"\"\"Service class that provides access to the customers\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Customer\n    RESOURCE_NAME = 'customers'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a customer.\n\n        Creates a new customer object.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              Customer\n        \"\"\"\n        path = '/customers'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List customers.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        customers.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Customer instances\n        \"\"\"\n        path = '/customers'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single customer.\n\n        Retrieves the details of an existing customer.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"CU\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Customer\n        \"\"\"\n        path = self._sub_url_params('/customers/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a customer.\n\n        Updates a customer object. Supports all of the fields supported when\n        creating a customer.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"CU\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Customer\n        \"\"\"\n        path = self._sub_url_params('/customers/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def remove(self,identity,params=None, headers=None):\n        \"\"\"Remove a customer.\n\n        Removed customers will not appear in search results or lists of\n        customers (in our API\n        or exports), and it will not be possible to load an individually\n        removed customer by\n        ID.\n        \n        <p class=\"restricted-notice\"><strong>The action of removing a customer\n        cannot be reversed, so please use with care.</strong></p>\n\n        Args:\n              identity (string): Unique identifier, beginning with \"CU\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Customer\n        \"\"\"\n        path = self._sub_url_params('/customers/:identity', {\n          \n            'identity': identity,\n          })\n        \n        response = self._perform_request('DELETE', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\customer_bank_accounts_service.py\nNome: customer_bank_accounts_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass CustomerBankAccountsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the customer_bank_accounts\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.CustomerBankAccount\n    RESOURCE_NAME = 'customer_bank_accounts'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a customer bank account.\n\n        Creates a new customer bank account object.\n        \n        There are three different ways to supply bank account details:\n        \n        - [Local details](#appendix-local-bank-details)\n        \n        - IBAN\n        \n        - [Customer Bank Account\n        Tokens](#javascript-flow-create-a-customer-bank-account-token)\n        \n        For more information on the different fields required in each country,\n        see [local bank details](#appendix-local-bank-details).\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              CustomerBankAccount\n        \"\"\"\n        path = '/customer_bank_accounts'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List customer bank accounts.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        bank accounts.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of CustomerBankAccount instances\n        \"\"\"\n        path = '/customer_bank_accounts'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single customer bank account.\n\n        Retrieves the details of an existing bank account.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BA\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              CustomerBankAccount\n        \"\"\"\n        path = self._sub_url_params('/customer_bank_accounts/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a customer bank account.\n\n        Updates a customer bank account object. Only the metadata parameter is\n        allowed.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BA\".\n              params (dict, optional): Request body.\n\n        Returns:\n              CustomerBankAccount\n        \"\"\"\n        path = self._sub_url_params('/customer_bank_accounts/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def disable(self,identity,params=None, headers=None):\n        \"\"\"Disable a customer bank account.\n\n        Immediately cancels all associated mandates and cancellable payments.\n        \n        This will return a `disable_failed` error if the bank account has\n        already been disabled.\n        \n        A disabled bank account can be re-enabled by creating a new bank\n        account resource with the same details.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"BA\".\n              params (dict, optional): Request body.\n\n        Returns:\n              CustomerBankAccount\n        \"\"\"\n        path = self._sub_url_params('/customer_bank_accounts/:identity/actions/disable', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\customer_notifications_service.py\nNome: customer_notifications_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass CustomerNotificationsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the customer_notifications\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.CustomerNotification\n    RESOURCE_NAME = 'customer_notifications'\n\n\n    def handle(self,identity,params=None, headers=None):\n        \"\"\"Handle a notification.\n\n        \"Handling\" a notification means that you have sent the notification\n        yourself (and\n        don't want GoCardless to send it).\n        If the notification has already been actioned, or the deadline to\n        notify has passed,\n        this endpoint will return an `already_actioned` error and you should\n        not take\n        further action. This endpoint takes no additional parameters.\n        \n\n        Args:\n              identity (string): The id of the notification.\n              params (dict, optional): Request body.\n\n        Returns:\n              CustomerNotification\n        \"\"\"\n        path = self._sub_url_params('/customer_notifications/:identity/actions/handle', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\events_service.py\nNome: events_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass EventsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the events\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Event\n    RESOURCE_NAME = 'events'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List events.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        events.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Event instances\n        \"\"\"\n        path = '/events'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single event.\n\n        Retrieves the details of a single event.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"EV\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Event\n        \"\"\"\n        path = self._sub_url_params('/events/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\instalment_schedules_service.py\nNome: instalment_schedules_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass InstalmentSchedulesService(base_service.BaseService):\n    \"\"\"Service class that provides access to the instalment_schedules\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.InstalmentSchedule\n    RESOURCE_NAME = 'instalment_schedules'\n\n\n    def create_with_dates(self,params=None, headers=None):\n        \"\"\"Create (with dates).\n\n        Creates a new instalment schedule object, along with the associated\n        payments. This\n        API is recommended if you know the specific dates you wish to charge.\n        Otherwise,\n        please check out the [scheduling\n        version](#instalment-schedules-create-with-schedule).\n        \n        The `instalments` property is an array of payment properties (`amount`\n        and\n        `charge_date`).\n        \n        It can take quite a while to create the associated payments, so the API\n        will return\n        the status as `pending` initially. When processing has completed, a\n        subsequent GET\n        request for the instalment schedule will either have the status\n        `success` and link\n        to the created payments, or the status `error` and detailed information\n        about the\n        failures.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              InstalmentSchedule\n        \"\"\"\n        path = '/instalment_schedules'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def create_with_schedule(self,params=None, headers=None):\n        \"\"\"Create (with schedule).\n\n        Creates a new instalment schedule object, along with the associated\n        payments. This\n        API is recommended if you wish to use the GoCardless scheduling logic.\n        For finer\n        control over the individual dates, please check out the [alternative\n        version](#instalment-schedules-create-with-dates).\n        \n        It can take quite a while to create the associated payments, so the API\n        will return\n        the status as `pending` initially. When processing has completed, a\n        subsequent\n        GET request for the instalment schedule will either have the status\n        `success` and link to\n        the created payments, or the status `error` and detailed information\n        about the\n        failures.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              InstalmentSchedule\n        \"\"\"\n        path = '/instalment_schedules'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List instalment schedules.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        instalment schedules.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of InstalmentSchedule instances\n        \"\"\"\n        path = '/instalment_schedules'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single instalment schedule.\n\n        Retrieves the details of an existing instalment schedule.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"IS\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              InstalmentSchedule\n        \"\"\"\n        path = self._sub_url_params('/instalment_schedules/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update an instalment schedule.\n\n        Updates an instalment schedule. This accepts only the metadata\n        parameter.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"IS\".\n              params (dict, optional): Request body.\n\n        Returns:\n              InstalmentSchedule\n        \"\"\"\n        path = self._sub_url_params('/instalment_schedules/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def cancel(self,identity,params=None, headers=None):\n        \"\"\"Cancel an instalment schedule.\n\n        Immediately cancels an instalment schedule; no further payments will be\n        collected for it.\n        \n        This will fail with a `cancellation_failed` error if the instalment\n        schedule is already cancelled or has completed.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"IS\".\n              params (dict, optional): Request body.\n\n        Returns:\n              InstalmentSchedule\n        \"\"\"\n        path = self._sub_url_params('/instalment_schedules/:identity/actions/cancel', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\institutions_service.py\nNome: institutions_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass InstitutionsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the institutions\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Institution\n    RESOURCE_NAME = 'institutions'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List Institutions.\n\n        Returns a list of supported institutions.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Institution instances\n        \"\"\"\n        path = '/institutions'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\mandates_service.py\nNome: mandates_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass MandatesService(base_service.BaseService):\n    \"\"\"Service class that provides access to the mandates\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Mandate\n    RESOURCE_NAME = 'mandates'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a mandate.\n\n        Creates a new mandate object.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              Mandate\n        \"\"\"\n        path = '/mandates'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List mandates.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        mandates.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Mandate instances\n        \"\"\"\n        path = '/mandates'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single mandate.\n\n        Retrieves the details of an existing mandate.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"MD\". Note that this prefix may not apply to mandates created before 2016.\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Mandate\n        \"\"\"\n        path = self._sub_url_params('/mandates/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a mandate.\n\n        Updates a mandate object. This accepts only the metadata parameter.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"MD\". Note that this prefix may not apply to mandates created before 2016.\n              params (dict, optional): Request body.\n\n        Returns:\n              Mandate\n        \"\"\"\n        path = self._sub_url_params('/mandates/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def cancel(self,identity,params=None, headers=None):\n        \"\"\"Cancel a mandate.\n\n        Immediately cancels a mandate and all associated cancellable payments.\n        Any metadata supplied to this endpoint will be stored on the mandate\n        cancellation event it causes.\n        \n        This will fail with a `cancellation_failed` error if the mandate is\n        already cancelled.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"MD\". Note that this prefix may not apply to mandates created before 2016.\n              params (dict, optional): Request body.\n\n        Returns:\n              Mandate\n        \"\"\"\n        path = self._sub_url_params('/mandates/:identity/actions/cancel', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def reinstate(self,identity,params=None, headers=None):\n        \"\"\"Reinstate a mandate.\n\n        <a name=\"mandate_not_inactive\"></a>Reinstates a cancelled or expired\n        mandate to the banks. You will receive a `resubmission_requested`\n        webhook, but after that reinstating the mandate follows the same\n        process as its initial creation, so you will receive a `submitted`\n        webhook, followed by a `reinstated` or `failed` webhook up to two\n        working days later. Any metadata supplied to this endpoint will be\n        stored on the `resubmission_requested` event it causes.\n        \n        This will fail with a `mandate_not_inactive` error if the mandate is\n        already being submitted, or is active.\n        \n        Mandates can be resubmitted up to 10 times.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"MD\". Note that this prefix may not apply to mandates created before 2016.\n              params (dict, optional): Request body.\n\n        Returns:\n              Mandate\n        \"\"\"\n        path = self._sub_url_params('/mandates/:identity/actions/reinstate', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\mandate_imports_service.py\nNome: mandate_imports_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass MandateImportsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the mandate_imports\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.MandateImport\n    RESOURCE_NAME = 'mandate_imports'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a new mandate import.\n\n        Mandate imports are first created, before mandates are added\n        one-at-a-time, so\n        this endpoint merely signals the start of the import process. Once\n        you've finished\n        adding entries to an import, you should\n        [submit](#mandate-imports-submit-a-mandate-import) it.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              MandateImport\n        \"\"\"\n        path = '/mandate_imports'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a mandate import.\n\n        Returns a single mandate import.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"IM\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              MandateImport\n        \"\"\"\n        path = self._sub_url_params('/mandate_imports/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def submit(self,identity,params=None, headers=None):\n        \"\"\"Submit a mandate import.\n\n        Submits the mandate import, which allows it to be processed by a member\n        of the\n        GoCardless team. Once the import has been submitted, it can no longer\n        have entries\n        added to it.\n        \n        In our sandbox environment, to aid development, we automatically\n        process mandate\n        imports approximately 10 seconds after they are submitted. This will\n        allow you to\n        test both the \"submitted\" response and wait for the webhook to confirm\n        the\n        processing has begun.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"IM\".\n              params (dict, optional): Request body.\n\n        Returns:\n              MandateImport\n        \"\"\"\n        path = self._sub_url_params('/mandate_imports/:identity/actions/submit', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def cancel(self,identity,params=None, headers=None):\n        \"\"\"Cancel a mandate import.\n\n        Cancels the mandate import, which aborts the import process and stops\n        the mandates\n        being set up in GoCardless. Once the import has been cancelled, it can\n        no longer have\n        entries added to it. Mandate imports which have already been submitted\n        or processed\n        cannot be cancelled.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"IM\".\n              params (dict, optional): Request body.\n\n        Returns:\n              MandateImport\n        \"\"\"\n        path = self._sub_url_params('/mandate_imports/:identity/actions/cancel', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\mandate_import_entries_service.py\nNome: mandate_import_entries_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass MandateImportEntriesService(base_service.BaseService):\n    \"\"\"Service class that provides access to the mandate_import_entries\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.MandateImportEntry\n    RESOURCE_NAME = 'mandate_import_entries'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Add a mandate import entry.\n\n        For an existing [mandate import](#core-endpoints-mandate-imports), this\n        endpoint can\n        be used to add individual mandates to be imported into GoCardless.\n        \n        You can add no more than 30,000 rows to a single mandate import.\n        If you attempt to go over this limit, the API will return a\n        `record_limit_exceeded` error.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              MandateImportEntry\n        \"\"\"\n        path = '/mandate_import_entries'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List all mandate import entries.\n\n        For an existing mandate import, this endpoint lists all of the entries\n        attached.\n        \n        After a mandate import has been submitted, you can use this endpoint to\n        associate records\n        in your system (using the `record_identifier` that you provided when\n        creating the\n        mandate import).\n        \n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of MandateImportEntry instances\n        \"\"\"\n        path = '/mandate_import_entries'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\mandate_pdfs_service.py\nNome: mandate_pdfs_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass MandatePdfsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the mandate_pdfs\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.MandatePdf\n    RESOURCE_NAME = 'mandate_pdfs'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a mandate PDF.\n\n        Generates a PDF mandate and returns its temporary URL.\n        \n        Customer and bank account details can be left blank (for a blank\n        mandate), provided manually, or inferred from the ID of an existing\n        [mandate](#core-endpoints-mandates).\n        \n        By default, we'll generate PDF mandates in English.\n        \n        To generate a PDF mandate in another language, set the\n        `Accept-Language` header when creating the PDF mandate to the relevant\n        [ISO 639-1](http://en.wikipedia.org/wiki/List_of_ISO_639-1_codes)\n        language code supported for the scheme.\n        \n        | Scheme           | Supported languages                               \n                                                                               \n                          |\n        | :--------------- |\n        :-------------------------------------------------------------------------------------------------------------------------------------------\n        |\n        | ACH              | English (`en`)                                    \n                                                                               \n                          |\n        | Autogiro         | English (`en`), Swedish (`sv`)                    \n                                                                               \n                          |\n        | Bacs             | English (`en`)                                    \n                                                                               \n                          |\n        | BECS             | English (`en`)                                    \n                                                                               \n                          |\n        | BECS NZ          | English (`en`)                                    \n                                                                               \n                          |\n        | Betalingsservice | Danish (`da`), English (`en`)                     \n                                                                               \n                          |\n        | PAD              | English (`en`)                                    \n                                                                               \n                          |\n        | SEPA Core        | Danish (`da`), Dutch (`nl`), English (`en`),\n        French (`fr`), German (`de`), Italian (`it`), Portuguese (`pt`),\n        Spanish (`es`), Swedish (`sv`) |\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              MandatePdf\n        \"\"\"\n        path = '/mandate_pdfs'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\payer_authorisations_service.py\nNome: payer_authorisations_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass PayerAuthorisationsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the payer_authorisations\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.PayerAuthorisation\n    RESOURCE_NAME = 'payer_authorisations'\n\n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single Payer Authorisation.\n\n        Retrieves the details of a single existing Payer Authorisation. It can\n        be used for polling the status of a Payer Authorisation.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PA\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              PayerAuthorisation\n        \"\"\"\n        path = self._sub_url_params('/payer_authorisations/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a Payer Authorisation.\n\n        Creates a Payer Authorisation. The resource is saved to the database\n        even if incomplete. An empty array of incomplete_fields means that the\n        resource is valid. The ID of the resource is used for the other\n        actions. This endpoint has been designed this way so you do not need to\n        save any payer data on your servers or the browser while still being\n        able to implement a progressive solution, such as a multi-step form.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              PayerAuthorisation\n        \"\"\"\n        path = '/payer_authorisations'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a Payer Authorisation.\n\n        Updates a Payer Authorisation. Updates the Payer Authorisation with the\n        request data. Can be invoked as many times as needed. Only fields\n        present in the request will be modified. An empty array of\n        incomplete_fields means that the resource is valid. This endpoint has\n        been designed this way so you do not need to save any payer data on\n        your servers or the browser while still being able to implement a\n        progressive solution, such a multi-step form. <p class=\"notice\"> Note\n        that in order to update the `metadata` attribute values it must be sent\n        completely as it overrides the previously existing values. </p>\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PA\".\n              params (dict, optional): Request body.\n\n        Returns:\n              PayerAuthorisation\n        \"\"\"\n        path = self._sub_url_params('/payer_authorisations/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def submit(self,identity,params=None, headers=None):\n        \"\"\"Submit a Payer Authorisation.\n\n        Submits all the data previously pushed to this PayerAuthorisation for\n        verification. This time, a 200 HTTP status is returned if the resource\n        is valid and a 422 error response in case of validation errors. After\n        it is successfully submitted, the Payer Authorisation can no longer be\n        edited.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PA\".\n              params (dict, optional): Request body.\n\n        Returns:\n              PayerAuthorisation\n        \"\"\"\n        path = self._sub_url_params('/payer_authorisations/:identity/actions/submit', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def confirm(self,identity,params=None, headers=None):\n        \"\"\"Confirm a Payer Authorisation.\n\n        Confirms the Payer Authorisation, indicating that the resources are\n        ready to be created.\n        A Payer Authorisation cannot be confirmed if it hasn't been submitted\n        yet.\n        \n        <p class=\"notice\">\n          The main use of the confirm endpoint is to enable integrators to\n        acknowledge the end of the setup process. \n          They might want to make the payers go through some other steps after\n        they go through our flow or make them go through the necessary\n        verification mechanism (upcoming feature).\n        </p>\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PA\".\n              params (dict, optional): Request body.\n\n        Returns:\n              PayerAuthorisation\n        \"\"\"\n        path = self._sub_url_params('/payer_authorisations/:identity/actions/confirm', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\payments_service.py\nNome: payments_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass PaymentsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the payments\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Payment\n    RESOURCE_NAME = 'payments'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a payment.\n\n        <a name=\"mandate_is_inactive\"></a>Creates a new payment object.\n        \n        This fails with a `mandate_is_inactive` error if the linked\n        [mandate](#core-endpoints-mandates) is cancelled or has failed.\n        Payments can be created against mandates with status of:\n        `pending_customer_approval`, `pending_submission`, `submitted`, and\n        `active`.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              Payment\n        \"\"\"\n        path = '/payments'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List payments.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        payments.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Payment instances\n        \"\"\"\n        path = '/payments'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single payment.\n\n        Retrieves the details of a single existing payment.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PM\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Payment\n        \"\"\"\n        path = self._sub_url_params('/payments/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a payment.\n\n        Updates a payment object. This accepts only the metadata parameter.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PM\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Payment\n        \"\"\"\n        path = self._sub_url_params('/payments/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def cancel(self,identity,params=None, headers=None):\n        \"\"\"Cancel a payment.\n\n        Cancels the payment if it has not already been submitted to the banks.\n        Any metadata supplied to this endpoint will be stored on the payment\n        cancellation event it causes.\n        \n        This will fail with a `cancellation_failed` error unless the payment's\n        status is `pending_submission`.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PM\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Payment\n        \"\"\"\n        path = self._sub_url_params('/payments/:identity/actions/cancel', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def retry(self,identity,params=None, headers=None):\n        \"\"\"Retry a payment.\n\n        <a name=\"retry_failed\"></a>Retries a failed payment if the underlying\n        mandate is active. You will receive a `resubmission_requested` webhook,\n        but after that retrying the payment follows the same process as its\n        initial creation, so you will receive a `submitted` webhook, followed\n        by a `confirmed` or `failed` event. Any metadata supplied to this\n        endpoint will be stored against the payment submission event it causes.\n        \n        This will return a `retry_failed` error if the payment has not failed.\n        \n        Payments can be retried up to 3 times.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PM\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Payment\n        \"\"\"\n        path = self._sub_url_params('/payments/:identity/actions/retry', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\payouts_service.py\nNome: payouts_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass PayoutsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the payouts\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Payout\n    RESOURCE_NAME = 'payouts'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List payouts.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        payouts.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Payout instances\n        \"\"\"\n        path = '/payouts'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single payout.\n\n        Retrieves the details of a single payout. For an example of how to\n        reconcile the transactions in a payout, see [this\n        guide](#events-reconciling-payouts-with-events).\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PO\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Payout\n        \"\"\"\n        path = self._sub_url_params('/payouts/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a payout.\n\n        Updates a payout object. This accepts only the metadata parameter.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"PO\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Payout\n        \"\"\"\n        path = self._sub_url_params('/payouts/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\payout_items_service.py\nNome: payout_items_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass PayoutItemsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the payout_items\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.PayoutItem\n    RESOURCE_NAME = 'payout_items'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"Get all payout items in a single payout.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of\n        items in the payout.\n        \n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of PayoutItem instances\n        \"\"\"\n        path = '/payout_items'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\redirect_flows_service.py\nNome: redirect_flows_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass RedirectFlowsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the redirect_flows\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.RedirectFlow\n    RESOURCE_NAME = 'redirect_flows'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a redirect flow.\n\n        Creates a redirect flow object which can then be used to redirect your\n        customer to the GoCardless hosted payment pages.\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              RedirectFlow\n        \"\"\"\n        path = '/redirect_flows'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single redirect flow.\n\n        Returns all details about a single redirect flow\n\n        Args:\n              identity (string): Unique identifier, beginning with \"RE\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              RedirectFlow\n        \"\"\"\n        path = self._sub_url_params('/redirect_flows/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def complete(self,identity,params=None, headers=None):\n        \"\"\"Complete a redirect flow.\n\n        This creates a [customer](#core-endpoints-customers), [customer bank\n        account](#core-endpoints-customer-bank-accounts), and\n        [mandate](#core-endpoints-mandates) using the details supplied by your\n        customer and returns the ID of the created mandate.\n        \n        This will return a `redirect_flow_incomplete` error if your customer\n        has not yet been redirected back to your site, and a\n        `redirect_flow_already_completed` error if your integration has already\n        completed this flow. It will return a `bad_request` error if the\n        `session_token` differs to the one supplied when the redirect flow was\n        created.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"RE\".\n              params (dict, optional): Request body.\n\n        Returns:\n              RedirectFlow\n        \"\"\"\n        path = self._sub_url_params('/redirect_flows/:identity/actions/complete', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\refunds_service.py\nNome: refunds_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass RefundsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the refunds\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Refund\n    RESOURCE_NAME = 'refunds'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a refund.\n\n        Creates a new refund object.\n        \n        This fails with:<a name=\"total_amount_confirmation_invalid\"></a><a\n        name=\"number_of_refunds_exceeded\"></a><a\n        name=\"available_refund_amount_insufficient\"></a>\n        \n        - `total_amount_confirmation_invalid` if the confirmation amount\n        doesn't match the total amount refunded for the payment. This safeguard\n        is there to prevent two processes from creating refunds without\n        awareness of each other.\n        \n        - `number_of_refunds_exceeded` if five or more refunds have already\n        been created against the payment.\n        \n        - `available_refund_amount_insufficient` if the creditor does not have\n        sufficient balance for refunds available to cover the cost of the\n        requested refund.\n        \n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              Refund\n        \"\"\"\n        path = '/refunds'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List refunds.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        refunds.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Refund instances\n        \"\"\"\n        path = '/refunds'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single refund.\n\n        Retrieves all details for a single refund\n\n        Args:\n              identity (string): Unique identifier, beginning with \"RF\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Refund\n        \"\"\"\n        path = self._sub_url_params('/refunds/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a refund.\n\n        Updates a refund object.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"RF\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Refund\n        \"\"\"\n        path = self._sub_url_params('/refunds/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\scenario_simulators_service.py\nNome: scenario_simulators_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass ScenarioSimulatorsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the scenario_simulators\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.ScenarioSimulator\n    RESOURCE_NAME = 'scenario_simulators'\n\n\n    def run(self,identity,params=None, headers=None):\n        \"\"\"Simulate a scenario.\n\n        Runs the specific scenario simulator against the specific resource\n\n        Args:\n              identity (string): The unique identifier of the simulator, used to initiate simulations. One of:\n<ul>\n<li>`creditor_verification_status_action_required`: Sets a creditor's `verification status` to `action required`, meaning that the creditor must provide further information to GoCardless in order to verify their account to receive payouts.</li>\n<li>`creditor_verification_status_in_review`: Sets a creditor's `verification status` to `in review`, meaning that the creditor has provided all of the information requested by GoCardless to verify their account, and is now awaiting review.</li>\n<li>`creditor_verification_status_successful`: Sets a creditor's `verification status` to `successful`, meaning that the creditor is fully verified and can receive payouts.</li>\n<li>`payment_confirmed`: Transitions a payment through to `confirmed`. It must start in the `pending_submission` state, and its mandate must be in the `activated` state (unless it is a payment for ACH, BECS, BECS_NZ or SEPA, in which cases the mandate may be `pending_submission`, since their mandates are submitted with their first payment).</li>\n<li>`payment_paid_out`: Transitions a payment through to `paid_out`, having been collected successfully and paid out to you. It must start in the `pending_submission` state, and its mandate must be in the `activated` state (unless it is a payment for ACH, BECS, BECS_NZ or SEPA, in which cases the mandate may be `pending_submission`, since their mandates are submitted with their first payment).</li>\n<li>`payment_failed`: Transitions a payment through to `failed`. It must start in the `pending_submission` state, and its mandate must be in the `activated` state (unless it is a payment for ACH, BECS, BECS_NZ or SEPA, in which cases the mandate may be `pending_submission`, since their mandates are submitted with their first payment).</li>\n<li>`payment_charged_back`: Behaves the same as the `payout_paid_out` simulator, except that the payment is transitioned to `charged_back` after it is paid out, having been charged back by the customer.</li>\n<li>`payment_chargeback_settled`: Behaves the same as the `payment_charged_back` simulator, except that the charged back payment is additionally included as a debit item in a payout, thereby settling the charged back payment.</li>\n<li>`payment_late_failure`: Transitions a payment through to `late_failure`, having been apparently collected successfully beforehand. It must start in the `pending_submission` state, and its mandate must be in the `activated` state (unless it is a payment for ACH, BECS, BECS_NZ or SEPA, in which cases the mandate may be `pending_submission`, since their mandates are submitted with their first payment). Not compatible with Autogiro mandates.</li>\n<li>`payment_late_failure_settled`: Behaves the same as the `payment_late_failure` simulator, except that the late failure is additionally included as a debit item in a payout, thereby settling the late failure.</li>\n<li>`payment_submitted`: Transitions a payment to `submitted`, without proceeding any further. It must start in the `pending_submission` state.</li>\n<li>`mandate_activated`: Transitions a mandate through to `activated`, having been submitted to the banks and set up successfully. It must start in the `pending_submission` state. Not compatible with ACH, BECS, BECS_NZ and SEPA mandates, which are submitted and activated with their first payment.</li>\n<li>`mandate_customer_approval_granted`: Transitions a mandate through to `pending_submission`, as if the customer approved the mandate creation. It must start in the `pending_customer_approval` state. Compatible only with Bacs and SEPA mandates, which support customer signatures on the mandate. All payments associated with the mandate will be transitioned to `pending_submission`. All subscriptions associated with the mandate will become `active`.</li>\n<li>`mandate_customer_approval_skipped`: Transitions a mandate through to `pending_submission`, as if the customer skipped the mandate approval during the mandate creation process. It must start in the `pending_customer_approval` state. Compatible only with Bacs and SEPA mandates, which support customer signatures on the mandate. All payments associated with the mandate will be transitioned to `pending_submission`. All subscriptions associated with the mandate will become `active`.</li>\n<li>`mandate_failed`: Transitions a mandate through to `failed`, having been submitted to the banks but found to be invalid (for example due to invalid bank details). It must start in the `pending_submission` or `submitted` states. Not compatible with SEPA mandates, which are submitted with their first payment.</li>\n<li>`mandate_expired`: Transitions a mandate through to `expired`, having been submitted to the banks, set up successfully and then expired because no collection attempts were made against it for longer than the scheme's dormancy period (13 months for Bacs, 3 years for SEPA, 15 months for ACH, Betalingsservice, and BECS). It must start in the `pending_submission` state. Not compatible with Autogiro, BECS NZ, and PAD mandates, which do not expire.</li>\n<li>`mandate_transferred`: Transitions a mandate through to `transferred`, having been submitted to the banks, set up successfully and then moved to a new bank account due to the customer using the UK's Current Account Switching Service (CASS). It must start in the `pending_submission` state. Only compatible with Bacs mandates.</li>\n<li>`mandate_transferred_with_resubmission`: Transitions a mandate through `transferred` and resubmits it to the banks, can be caused be the UK's Current Account Switching Service (CASS) or when a customer contacts GoCardless to change their bank details. It must start in the `pending_submission` state. Only compatible with Bacs, SEPA and Autogiro mandates.</li>\n<li>`refund_paid`: Transitions a refund to `paid`. It must start in either the `pending_submission` or `submitted` state.</li>\n<li>`refund_settled`: Transitions a refund to `paid`, if it's not already, then generates a payout that includes the refund, thereby settling the funds. It must start in one of `pending_submission`, `submitted` or `paid` states.</li>\n<li>`refund_bounced`: Transitions a refund to `bounced`. It must start in either the `pending_submission`, `submitted`, or `paid` state.</li>\n<li>`refund_returned`: Transitions a refund to `refund_returned`. The refund must start in `pending_submission`.</li>\n<li>`payout_bounced`: Transitions a payout to `bounced`. It must start in the `paid` state.</li>\n<li>`billing_request_fulfilled`: Authorises the billing request, and then fulfils it. The billing request must be in the `pending` state, with all actions completed except for `bank_authorisation`. Only billing requests with a `payment_request` are supported.</li>\n<li>`billing_request_fulfilled_and_payment_failed`: Authorises the billing request, fulfils it, and moves the associated payment to `failed`. The billing request must be in the `pending` state, with all actions completed except for `bank_authorisation`. Only billing requests with a `payment_request` are supported.</li>\n<li>`billing_request_fulfilled_and_payment_paid_out`: Authorises the billing request, fulfils it, and moves the associated payment to `paid_out`. The billing request must be in the `pending` state, with all actions completed except for `bank_authorisation`. Only billing requests with a `payment_request` are supported.</li>\n</ul>\n              params (dict, optional): Request body.\n\n        Returns:\n              ScenarioSimulator\n        \"\"\"\n        path = self._sub_url_params('/scenario_simulators/:identity/actions/run', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\subscriptions_service.py\nNome: subscriptions_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass SubscriptionsService(base_service.BaseService):\n    \"\"\"Service class that provides access to the subscriptions\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Subscription\n    RESOURCE_NAME = 'subscriptions'\n\n\n    def create(self,params=None, headers=None):\n        \"\"\"Create a subscription.\n\n        Creates a new subscription object\n\n        Args:\n              params (dict, optional): Request body.\n\n        Returns:\n              Subscription\n        \"\"\"\n        path = '/subscriptions'\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        try:\n          response = self._perform_request('POST', path, params, headers,\n                                            retry_failures=True)\n        except errors.IdempotentCreationConflictError as err:\n          if self.raise_on_idempotency_conflict:\n            raise err\n          return self.get(identity=err.conflicting_resource_id,\n                          params=params,\n                          headers=headers)\n        return self._resource_for(response)\n  \n\n    def list(self,params=None, headers=None):\n        \"\"\"List subscriptions.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        subscriptions.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Subscription instances\n        \"\"\"\n        path = '/subscriptions'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single subscription.\n\n        Retrieves the details of a single subscription.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"SB\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Subscription\n        \"\"\"\n        path = self._sub_url_params('/subscriptions/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def update(self,identity,params=None, headers=None):\n        \"\"\"Update a subscription.\n\n        Updates a subscription object.\n        \n        This fails with:\n        \n        - `validation_failed` if invalid data is provided when attempting to\n        update a subscription.\n        \n        - `subscription_not_active` if the subscription is no longer active.\n        \n        - `subscription_already_ended` if the subscription has taken all\n        payments.\n        \n        - `mandate_payments_require_approval` if the amount is being changed\n        and the mandate requires approval.\n        \n        - `number_of_subscription_amendments_exceeded` error if the\n        subscription amount has already been changed 10 times.\n        \n        - `forbidden` if the amount is being changed, and the subscription was\n        created by an app and you are not authenticated as that app, or if the\n        subscription was not created by an app and you are authenticated as an\n        app\n        \n        - `resource_created_by_another_app` if the app fee is being changed,\n        and the subscription was created by an app other than the app you are\n        authenticated as\n        \n\n        Args:\n              identity (string): Unique identifier, beginning with \"SB\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Subscription\n        \"\"\"\n        path = self._sub_url_params('/subscriptions/:identity', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {self._envelope_key(): params}\n\n        response = self._perform_request('PUT', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def pause(self,identity,params=None, headers=None):\n        \"\"\"Pause a subscription.\n\n        Pause a subscription object.\n        No payments will be created until it is resumed.\n        \n        This can only be used when a subscription is collecting a fixed number\n        of payments (created using `count`),\n        when they continue forever (created without `count` or `end_date`) or\n        the subscription is already paused for a number of cycles.\n        \n        When `pause_cycles` is omitted the subscription is paused until the\n        [resume endpoint](#subscriptions-resume-a-subscription) is called.\n        If the subscription is collecting a fixed number of payments,\n        `end_date` will be set to `null`.\n        When paused indefinitely, `upcoming_payments` will be empty.\n        \n        When `pause_cycles` is provided the subscription will be paused for the\n        number of cycles requested.\n        If the subscription is collecting a fixed number of payments,\n        `end_date` will be set to a new value.\n        When paused for a number of cycles, `upcoming_payments` will still\n        contain the upcoming charge dates.\n        \n        This fails with:\n        \n        - `forbidden` if the subscription was created by an app and you are not\n        authenticated as that app, or if the subscription was not created by an\n        app and you are authenticated as an app\n        \n        - `validation_failed` if invalid data is provided when attempting to\n        pause a subscription.\n        \n        - `subscription_paused_cannot_update_cycles` if the subscription is\n        already paused for a number of cycles and the request provides a value\n        for `pause_cycle`.\n        \n        - `subscription_cannot_be_paused` if the subscription cannot be paused.\n        \n        - `subscription_already_ended` if the subscription has taken all\n        payments.\n        \n        - `pause_cycles_must_be_greater_than_or_equal_to` if the provided value\n        for `pause_cycles` cannot be satisfied.\n        \n\n        Args:\n              identity (string): Unique identifier, beginning with \"SB\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Subscription\n        \"\"\"\n        path = self._sub_url_params('/subscriptions/:identity/actions/pause', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def resume(self,identity,params=None, headers=None):\n        \"\"\"Resume a subscription.\n\n        Resume a subscription object.\n        Payments will start to be created again based on the subscriptions\n        recurrence rules.\n        The `charge_date` on the next payment will be the same as the\n        subscriptions `earliest_charge_date_after_resume`\n        \n        This fails with:\n        \n        - `forbidden` if the subscription was created by an app and you are not\n        authenticated as that app, or if the subscription was not created by an\n        app and you are authenticated as an app\n        \n        - `validation_failed` if invalid data is provided when attempting to\n        resume a subscription.\n        \n        - `subscription_not_paused` if the subscription is not paused.\n        \n\n        Args:\n              identity (string): Unique identifier, beginning with \"SB\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Subscription\n        \"\"\"\n        path = self._sub_url_params('/subscriptions/:identity/actions/resume', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n    def cancel(self,identity,params=None, headers=None):\n        \"\"\"Cancel a subscription.\n\n        Immediately cancels a subscription; no more payments will be created\n        under it. Any metadata supplied to this endpoint will be stored on the\n        payment cancellation event it causes.\n        \n        This will fail with a cancellation_failed error if the subscription is\n        already cancelled or finished.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"SB\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Subscription\n        \"\"\"\n        path = self._sub_url_params('/subscriptions/:identity/actions/cancel', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\tax_rates_service.py\nNome: tax_rates_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass TaxRatesService(base_service.BaseService):\n    \"\"\"Service class that provides access to the tax_rates\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.TaxRate\n    RESOURCE_NAME = 'tax_rates'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List tax rates.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of all\n        tax rates.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of TaxRate instances\n        \"\"\"\n        path = '/tax_rates'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single tax rate.\n\n        Retrieves the details of a tax rate.\n\n        Args:\n              identity (string): The unique identifier created by the jurisdiction, tax type and version\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              TaxRate\n        \"\"\"\n        path = self._sub_url_params('/tax_rates/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\webhooks_service.py\nNome: webhooks_service.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom . import base_service\nfrom .. import resources\nfrom ..paginator import Paginator\nfrom .. import errors\n\nclass WebhooksService(base_service.BaseService):\n    \"\"\"Service class that provides access to the webhooks\n    endpoints of the GoCardless Pro API.\n    \"\"\"\n\n    RESOURCE_CLASS = resources.Webhook\n    RESOURCE_NAME = 'webhooks'\n\n\n    def list(self,params=None, headers=None):\n        \"\"\"List webhooks.\n\n        Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your\n        webhooks.\n\n        Args:\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              ListResponse of Webhook instances\n        \"\"\"\n        path = '/webhooks'\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n\n    def all(self, params=None):\n        if params is None:\n            params = {}\n        return Paginator(self, params)\n    \n  \n\n    def get(self,identity,params=None, headers=None):\n        \"\"\"Get a single webhook.\n\n        Retrieves the details of an existing webhook.\n\n        Args:\n              identity (string): Unique identifier, beginning with \"WB\".\n              params (dict, optional): Query string parameters.\n\n        Returns:\n              Webhook\n        \"\"\"\n        path = self._sub_url_params('/webhooks/:identity', {\n          \n            'identity': identity,\n          })\n        \n\n        response = self._perform_request('GET', path, params, headers,\n                                         retry_failures=True)\n        return self._resource_for(response)\n  \n\n    def retry(self,identity,params=None, headers=None):\n        \"\"\"Retry a webhook.\n\n        Requests for a previous webhook to be sent again\n\n        Args:\n              identity (string): Unique identifier, beginning with \"WB\".\n              params (dict, optional): Request body.\n\n        Returns:\n              Webhook\n        \"\"\"\n        path = self._sub_url_params('/webhooks/:identity/actions/retry', {\n          \n            'identity': identity,\n          })\n        \n        if params is not None:\n            params = {'data': params}\n        response = self._perform_request('POST', path, params, headers,\n                                         retry_failures=False)\n        return self._resource_for(response)\n  \n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\gocardless_pro\\services\\__init__.py\nNome: __init__.py\n----------------------------------------\n# WARNING: Do not edit by hand, this file was generated by Crank:\n#\n#   https://github.com/gocardless/crank\n#\n\nfrom .bank_authorisations_service import BankAuthorisationsService\nfrom .bank_details_lookups_service import BankDetailsLookupsService\nfrom .billing_requests_service import BillingRequestsService\nfrom .billing_request_flows_service import BillingRequestFlowsService\nfrom .billing_request_templates_service import BillingRequestTemplatesService\nfrom .blocks_service import BlocksService\nfrom .creditors_service import CreditorsService\nfrom .creditor_bank_accounts_service import CreditorBankAccountsService\nfrom .currency_exchange_rates_service import CurrencyExchangeRatesService\nfrom .customers_service import CustomersService\nfrom .customer_bank_accounts_service import CustomerBankAccountsService\nfrom .customer_notifications_service import CustomerNotificationsService\nfrom .events_service import EventsService\nfrom .instalment_schedules_service import InstalmentSchedulesService\nfrom .institutions_service import InstitutionsService\nfrom .mandates_service import MandatesService\nfrom .mandate_imports_service import MandateImportsService\nfrom .mandate_import_entries_service import MandateImportEntriesService\nfrom .mandate_pdfs_service import MandatePdfsService\nfrom .payer_authorisations_service import PayerAuthorisationsService\nfrom .payments_service import PaymentsService\nfrom .payouts_service import PayoutsService\nfrom .payout_items_service import PayoutItemsService\nfrom .redirect_flows_service import RedirectFlowsService\nfrom .refunds_service import RefundsService\nfrom .scenario_simulators_service import ScenarioSimulatorsService\nfrom .subscriptions_service import SubscriptionsService\nfrom .tax_rates_service import TaxRatesService\nfrom .webhooks_service import WebhooksService\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\models\\models.py\nNome: models.py\n----------------------------------------\n# -*- coding: utf-8 -*-\n\nfrom odoo import models, fields, api, exceptions\nimport logging\nimport datetime\nimport json\nimport time\n\nimport uuid\nimport werkzeug\n\nfrom werkzeug import urls\n\n_logger = logging.getLogger(__name__)\n\ntry:\n    from .. import gocardless_pro\nexcept ImportError as err:\n    _logger.debug(err)    \n#endtry\n\nclass GC_Importer(models.TransientModel):\n    _inherit = 'base_import.import'\n\n    \n    def execute_import(self, fields, columns, options, dryrun=False):\n        res_import = super(GC_Importer, self).execute_import(fields, columns, options, dryrun)\n\n        # if we're in a dryrun then don't do anything\n        if dryrun:\n            return res_import\n\n        # we only want to override for gocardless.mandate models\n        if self.res_model == 'gocardless.mandate':\n            # it's go time!\n            for m in self.env['gocardless.mandate'].sudo().search(['&',('partner_id','=?',False),('partner_email','!=','')]):\n#                try:\n                    p = self.env['res.partner'].sudo().search(['&',('mandate_id','=',False),('email','=',m.partner_email)], limit=1)\n                    _logger.debug(\"Matched mandate {} to {}\".format(m.gc_mandate_id, p.name))\n                    m.write({\n                        'partner_id': p.id,\n                        #'gc_last_state_change': datetime.date.today()\n                    })\n                    p.write({\n                        'gc_state': 'complete',\n                        'mandate_id': m.id\n                    })\n#                except:\n#                    continue\n            #rof\n        #endif\n        return res_import\n    #end do\n\n#end GC_Importer\n\n\nclass GCPayment(models.Model):\n    _name = 'gocardless.payment'\n    _description = 'GoCardless Payment'\n    \n    _rec_name   = 'gc_payment_id'\n\n    amount = fields.Float(\"Transaction amount\")\n    \n    claim_date  = fields.Datetime(\"Date claimed\")\n    post_date   = fields.Datetime(\"Date posted\")\n    payout_date = fields.Datetime(\"Date paid out\")\n\n    gc_payment_state = fields.Selection([\n        ['pending','Pending'],\n        ['created','Created'],\n        ['pending_customer_approval','Pending Customer Approval'],\n        ['customer_approval_granted','Customer approval: Granted'],\n        ['customer_approval_rejected','Customer approval: Rejected'],\n        ['customer_approval_denied', 'Customer approval: Denied'],\n        ['pending_submission','Pending Submission'],\n        ['submitted','Submitted'],\n        ['confirmed','Confirmed'],\n        ['cancelled','Cancelled'],\n        ['failed','Failed'],\n        ['charged_back','Charged back'],\n        ['chargeback_cancelled','Chargeback cancelled'],\n        ['paid_out','Paid out'],\n        ['late_failure_settled','Late failure settled'],\n        ['chargeback_settled','Chargeback settled'],\n        ['resubmission_requested','Resubmission requested']        \n    ], \n        string=\"Payment State\",\n        default='created'\n    )\n\n    last_state_change = fields.Datetime(\"Last state change on\")\n\n    gc_payment_id = fields.Char(\"Transaction ID\")\n    \n    invoice_id = fields.Many2one('account.move')\n\n    mandate_id  = fields.Many2one(comodel_name='gocardless.mandate',string='Mandate')\n\n    event_ids   = fields.One2many(comodel_name='gocardless.event', inverse_name='payment_id', string=\"Events\")\n\n    \n    def updatePaymentsBatchRun(self):\n        # Method no longer used - keeping its stub to avoid\n        # unnecessary cron exceptions\n        _logger.warning(\"Deprecated cron job: remove 'Gocardless: Payment Update Batch' from scheduled actions\")        \n        pass\n\n    \n    def retry_payment(self):\n        ICPSudo = self.env['ir.config_parameter'].sudo()\n        client = gocardless_pro.Client(\n            access_token = ICPSudo.get_param('gocardless.gc_access_token'),\n            environment = ICPSudo.get_param('gocardless.gc_environment')\n        )\n\n        ret = False\n        try:\n            ret = client.payments.retry(self.gc_payment_id)\n        except gocardless_pro.errors.ApiError as inst:\n            raise exceptions.UserError(\n                \"The payment retry could not be completed for the following reason: {}\"\n                .format(\n                    inst.message\n                )\n            )\n            return\n\n        self.write({'gc_payment_state': 'pending'})\n        return ret\n        \n\n\n    \n    def gc_cancel_payment(self):\n        ICPSudo = self.env['ir.config_parameter'].sudo()\n        client = gocardless_pro.Client(\n            access_token = ICPSudo.get_param('gocardless.gc_access_token'),\n            environment = ICPSudo.get_param('gocardless.gc_environment')\n        )\n\n        try:\n            client.payments.cancel(self.gc_payment_id)\n        except gocardless_pro.errors.ApiError as inst:\n            raise exceptions.UserError(\n                \"The payment could not be cancelled for the following reason: {}\"\n                .format(\n                    inst.message\n                )\n            )\n\n\n#end GCPayment\n\nclass Invoice(models.Model):\n    _inherit = 'account.move'\n\n    # Odoo 13 compatibility thunks\n    number = fields.Char(related='name', store=False)\n\n    gc_last_payment_attempt = fields.Datetime(\"Date of last payment attempt\", copy=False)\n\n    gc_payment_attempted = fields.Boolean(\"GC Charged\", copy=False)\n\n    # calculate default value for pay_by_gc\n    def _gc_get_pay_by_gc(self):\n        for rec in self:\n            return rec.partner_id.use_gc\n\n    # gc_pay_by_gc = fields.Boolean(\"Take payment for this invoice by GoCardless\", default=_gc_get_pay_by_gc)\n    \n    gc_retry_payment = fields.Boolean(\"Retry payment?\", copy=False)\n\n    gc_enable_payment_recreate = fields.Boolean(\"Recreate payment available\", default=False, copy=False)\n\n    gc_payments = fields.One2many(string=\"Payment Records\", comodel_name='gocardless.payment', inverse_name='invoice_id', copy=False)\n\n    active_payment_id   = fields.Many2one(comodel_name='gocardless.payment', string='Current Payment', copy=False)\n\n    gc_display_gc = fields.Boolean(string=\"GoCardless Chargeable\", store=False, compute='_compute_display_gc', search='_display_gc_search', copy=False)\n\n    @api.depends('partner_id')\n    def _compute_display_gc(self):\n        if (self.env['ir.config_parameter'].sudo().get_param('gocardless.gc_access_token') not in ['', False, None]):\n            for rec in self:\n                rec.gc_display_gc = (rec.partner_id.gc_state not in ['setup', 'pending'])\n        else:\n            for rec in self:\n                rec.gc_display_gc = False\n\n    def _display_gc_search(self, operator, value):\n        recs = self.search([]).filtered(lambda x : x.gc_display_gc is True)\n        if recs:\n            return [('id', 'in', [x.id for x in recs])]\n\n    @api.onchange('partner_id')\n    def _onchange_partner(self):\n        #self.gc_pay_by_gc = self.partner_id.use_gc\n        pass\n        \n\n    \n    def action_gocardless_retry_payment(self):\n        oops = False\n        try:\n            return self.active_payment_id.retry_payment()\n        except exceptions.UserError as inst:\n            _logger.debug(\"OOPS\")\n            oops = inst\n            if \"inactive mandate\" in inst.message:\n                _logger.debug(\"Enabling recreate button\")\n                self.gc_enable_payment_recreate = True\n                self.write({\n                    'gc_enable_payment_recreate': True\n                })\n                self.env.cr.commit()\n        finally:            \n            if oops:\n                _logger.debug(\"We got an oops, raising it\")\n                raise oops\n        # self.gc_retry_payment = True\n        # return self.action_gocardless_take_payment()\n\n    \n    def action_gocardless_recreate_payment(self):\n        self.gc_retry_payment = True\n        return self.action_gocardless_take_payment()        \n\n    \n    def action_gocardless_take_payment(self):\n        invoice = self\n        \n        ICPSudo = self.env['ir.config_parameter'].sudo()\n        client = gocardless_pro.Client(\n            access_token = ICPSudo.get_param('gocardless.gc_access_token'),\n            environment = ICPSudo.get_param('gocardless.gc_environment')\n        )\n\n        try:\n            payment = client.payments.create(\n                params = {\n                    \"amount\" : int((invoice.amount_total * 100)), # format amount in cents\n                    \"app_fee\" : int((invoice.amount_total * 100) * 0.01), # DO NOT MODIFY THIS LINE, IT IS HOW WE GET PAID FOR OUR WORK. MODIFYING THIS LINE WILL VOID YOUR SUPPORT.\n                    \"currency\" : invoice.currency_id.name,\n                    \"retry_if_possible\": True,\n                    \"links\" : {\n                        \"mandate\" : invoice.partner_id.gc_mandate_id\n                    },\n                    \"metadata\": {\n                        \"invoice_number\": invoice.number\n                    }\n                },\n                headers = {\n                    'Idempotency-Key': '{}-{}'.format(invoice.partner_id.gc_mandate_id, invoice.number) if not invoice.gc_retry_payment else 'retry-{}-{}-{}'.format(invoice.partner_id.gc_mandate_id, invoice.number, datetime.datetime.now())\n                                                        # this key allows us to set a unique id for the tx in question\n                                                        # - making sure we don't accidentally bill a partner twice\n                }\n            )\n        except gocardless_pro.errors.ApiError as inst:\n            raise exceptions.Warning(\n                \"Payment could not be submitted to GoCardless for the following reason: {}\"\n                .format(\n                    inst.message\n                )\n            )\n\n        invoice.write({\n            'gc_last_payment_attempt': datetime.datetime.now(),\n            'gc_payment_attempted': True,           # we've attempted to take payment\n            'gc_retry_payment': False,              # if we've done a manual retry, cancel this too\n            'gc_enable_payment_recreate': False     # we definitely want to cancel this one\n            })\n\n        mandate = self.env['gocardless.mandate'].search([('gc_mandate_id','=',invoice.partner_id.gc_mandate_id)], limit=1)\n\n        p = self.env['gocardless.payment'].sudo().create({\n            'amount': invoice.amount_total,\n            'claim_date': datetime.datetime.now(),\n            'mandate_id': mandate.id,\n            'gc_payment_state': 'pending',\n            'gc_payment_id': payment.id,\n            'invoice_id': invoice.id\n        })\n\n        invoice.write({\n            'active_payment_id': p.id\n        })\n\n        invoice.message_post(body=\"GoCardless payment requested for {} {} with payment ID {}\".format(\n            invoice.currency_id.name, invoice.amount_total, payment.id\n        ))\n        time.sleep(0.1) # important to avoid GoCardless API flooding & rate limit exceptions\n\n    \n    def takePaymentBatchRun(self):\n        _logger.warning(\"Deprecated cron job: remove 'Gocardless: Invoice Take Payment Batch' from scheduled actions\")\n        pass\n\n    def processPaymentEvent(self, event, gc_payment, journal):\n        payment = self.env['account.payment.register'].with_context(active_model='account.move',active_ids=[self.id])\n        payment.create({\n            'payment_type': 'inbound',\n            'amount': gc_payment.amount,\n            'payment_date': datetime.date.today(),\n            'journal_id': int(journal.id),\n            'currency_id': int(self.currency_id.id),\n            'communication': self.number,                            \n            'partner_type': 'customer', #TODO: sort out the hardcoded bit here if needed\n            'partner_id': int(self.partner_id.id),\n        }).action_create_payments()\n\n\n#end Invoice\n\nclass GC_Mandate(models.Model):\n    _name = 'gocardless.mandate'\n    _description = 'GoCardless Mandate'\n\n    _rec_name   = 'gc_mandate_id'\n\n    gc_state    = fields.Selection(\n        [\n            ['pending','Pending'],\n            ['created','Created'],\n            ['pending_submission','Pending Submission'],\n            ['submitted','Submitted'],\n            ['active','Active'],\n            ['reinstated','Reinstated'],\n            ['cancelled','Cancelled'],\n            ['failed','Failed'],\n            ['consumed','Consumed'],\n            ['blocked','Blocked'],\n            ['suspended_by_payer','Suspended by payer'],\n            ['expired','Expired'],\n            ['resubmission_requested','Resubmission requested'],\n            ['replaced','Replaced'],\n            ['pending_customer_approval','Pending customer approval'],\n            ['customer_approval_granted','Customer approval granted'],\n            ['customer_approval_skipped','Customer approval skipped']\n        ], \n        string=\"Mandate state:\",\n        required=True\n    )\n\n    gc_last_state_change = fields.Date(\"Last updated\", \n        default=datetime.date(year=1970,month=1,day=1)\n    )\n\n    gc_mandate_id       = fields.Char(\"GoCardless Mandate ID\", required=True)\n\n    event_ids           = fields.One2many(comodel_name='gocardless.event', inverse_name='mandate_id', string=\"Events\")\n\n    partner_id          = fields.Many2one(comodel_name='res.partner', string='Partner')\n    partner_email       = fields.Char(string='Email', related='partner_id.email', store=True, readonly=False)\n\n    \n    def mandateUpdate(self):\n        # Method no longer used - keeping its stub to avoid\n        # unnecessary cron exceptions\n        _logger.warning(\"Deprecated cron job: remove 'Gocardless: Mandate Update Batch' from scheduled actions\")\n        pass\n\n#end GC_Mandate\n\n\nclass GC_Event(models.Model):\n    _name = 'gocardless.event'\n    _description = 'GoCardless Event'\n\n    _rec_name = 'event_id'\n\n    event_id        = fields.Char(string=\"GoCardless Event ID\")\n    action          = fields.Char(string=\"Action\")\n    created_at      = fields.Datetime(string=\"Event Date\")\n\n    cause           = fields.Char(string=\"Reason\")\n    ev_description  = fields.Char(string=\"Reason Description\")\n    \n    ev_origin       = fields.Selection(\n        selection = [\n            ('bank','Bank'),\n            ('gocardless','GoCardless'),\n            ('api','API'),\n            ('customer','Customer'),\n            ('payer','Payer')\n        ],\n        string=\"Event origin\"\n    )\n\n    ev_reason_code  = fields.Char(string=\"Bank Reason Code\")\n    ev_scheme       = fields.Char(string=\"Direct Debit Scheme\")\n\n    resource_type   = fields.Selection(\n        selection = [\n            ('payments','Payment'),\n            ('mandates','Mandate'),\n            ('payouts','Payout'),\n            ('refunds','Refunds'),\n            ('subscriptions','Subscriptions'),\n            ('creditors', 'Creditors'),\n            ('billing_requests','Billing Requests'),\n            ('instalment_schedules','Instalment Schedule'),\n            ('payer_authorisations','Payer Authorisation')\n        ],\n        string=\"Resource type\"\n    )\n\n    payment_id      = fields.Many2one(comodel_name='gocardless.payment',string=\"Payment\")\n    mandate_id      = fields.Many2one(comodel_name='gocardless.mandate',string=\"Mandate\")\n\n    \n    def do_full_event_refresh(self):\n        self.process_events()\n\n    \n    def doEvents(self):\n        # we're in the batch run, so pick up the last 14 days\n        date_cutoff = \"{}T{}Z\".format(datetime.date.today() - datetime.timedelta(days=14), datetime.datetime.min.time())        \n        self.process_events(date_cutoff)\n\n    def process_events(self, date_cutoff=None):\n        # Here we go with one huge-ass batch run...\n        # It's about here that I started to lose my mind ;-)\n\n        ICPSudo = self.env['ir.config_parameter'].sudo()\n        gctoken = ICPSudo.get_param('gocardless.gc_access_token')\n        gcenv = ICPSudo.get_param('gocardless.gc_environment')\n\n        client = gocardless_pro.Client(\n            access_token = gctoken,\n            environment = gcenv\n        )\n\n        events = client.events.list(\n            params = {\n                \"created_at[gte]\": date_cutoff\n            } if date_cutoff else {\n                \"limit\": 500\n            }\n        ).records\n        \n        count = 0\n        for event in events:\n            # Heavy lifting loop. Should probably look at refactoring this into an event dispatcher.\n            # Actually yeah, that's a good idea.\n            # Edit: we did it.\n            \n            # anyway, to business.\n\n            existing_event = False\n\n            # first, make sure we don't already have the event ID in the database.\n            if len(self.search([('event_id','=',event.id)])._ids) > 0:\n                # event already exists (length of search result > 0),\n                # so get on with the next one\n                existing_event = self.env['gocardless.event'].sudo().search([('event_id','=',event.id)], limit=1)\n\n            # parse the date into a format Python (and thus Odoo) actually likes:\n            eventDate = datetime.datetime.strptime(event.created_at, \"%Y-%m-%dT%H:%M:%S.%fZ\")\n\n            if not existing_event:\n            # let's go ahead and create the event\n                self.env['gocardless.event'].sudo().create({\n                    'event_id':         event.id,\n                    'action':           event.action,\n                    'created_at':       eventDate,\n                    'cause':            event.details.cause,\n                    'ev_description':   event.details.description,\n                    'ev_origin':        event.details.origin,\n                    'ev_reason_code':   event.details.reason_code,\n                    'ev_scheme':        event.details.scheme,\n                    'resource_type':    event.resource_type,\n                    'mandate_id':       self.env['gocardless.mandate'].search([('gc_mandate_id','=',event.links.mandate)], limit=1).id if event.resource_type == 'mandates' else None,\n                    'payment_id':       self.env['gocardless.payment'].search([('gc_payment_id','=',event.links.payment)], limit=1).id if event.resource_type == 'payments' else None                \n                })\n            else:\n                # event already exists\n                # are we in a reprocess? let's work this out from what we know\n                if date_cutoff:\n                    # there's a cutoff date specified, so no we're not\n                    continue\n                else:\n                    # we're in a reprocess, update the event\n                    existing_event.write({\n                        'event_id':         event.id,\n                        'action':           event.action,\n                        'created_at':       eventDate,\n                        'cause':            event.details.cause,\n                        'ev_description':   event.details.description,\n                        'ev_origin':        event.details.origin,\n                        'ev_reason_code':   event.details.reason_code,\n                        'ev_scheme':        event.details.scheme,\n                        'resource_type':    event.resource_type,\n                        'mandate_id':       self.env['gocardless.mandate'].search([('gc_mandate_id','=',event.links.mandate)], limit=1).id if event.resource_type == 'mandates' else None,\n                        'payment_id':       self.env['gocardless.payment'].search([('gc_payment_id','=',event.links.payment)], limit=1).id if event.resource_type == 'payments' else None                \n                    })\n\n\n\n            if event.resource_type == 'payments':\n                self.dispatchPaymentEvents(event)\n            elif event.resource_type == 'mandates':\n                self.dispatchMandateEvents(event)\n            #endif\n\n            count += 1\n\n        #rof\n        _logger.info('Processed {} events'.format(count))\n    #end doEvents\n\n    def dispatchPaymentEvents(self, event):\n        ICPSudo = self.env['ir.config_parameter'].sudo()\n\n        post_journals = ICPSudo.get_param('gocardless.gc_keep_journal')\n        jid = ICPSudo.get_param('gocardless.gc_journal_id')\n        journal = self.env['account.journal'].search([('id','=',jid)])\n\n\n        gc_payments = self.env['gocardless.payment'].sudo().search([('gc_payment_id','=',event.links.payment)])\n        for gc_payment in gc_payments:\n            eventDate = datetime.datetime.strptime(event.created_at, \"%Y-%m-%dT%H:%M:%S.%fZ\")\n            if (gc_payment.gc_payment_state != event.action) and (eventDate > (fields.Datetime.from_string(gc_payment.last_state_change) if gc_payment.last_state_change else datetime.datetime(1970,1,1))):     \n                # let's check we actually need to update something (disabled for debug)\n                # pick up the previous state\n                prev_state = gc_payment.gc_payment_state                \n                vals = {\n                    'gc_payment_state': event.action\n                }\n\n                # updated logic to catch missed 'confirmed' events\n                if (event.action == 'confirmed') or (event.action == 'paid_out' and prev_state != 'confirmed'):\n                    vals.update({'post_date': eventDate})\n                    \n                    if post_journals:\n                        gc_payment.invoice_id.processPaymentEvent(event, gc_payment, journal)\n                    #endif\n                #endif\n\n                if event.action == 'paid_out':\n                    vals.update({'payout_date': eventDate})\n\n                vals.update({'last_state_change': eventDate})\n                gc_payment.write(vals)\n\n                msg = \"Payment update: Payment ID {} State: {} Amount: {}\".format(gc_payment.gc_payment_id, gc_payment.gc_payment_state, gc_payment.amount)\n                gc_payment.invoice_id.message_post(body=msg)\n\n            #endif\n\n        pass\n\n    def dispatchMandateEvents(self, event):\n        \n        for mandate in self.env['gocardless.mandate'].sudo().search([('gc_mandate_id','=',event.links.mandate)]):\n            eventDate = datetime.datetime.strptime(event.created_at, \"%Y-%m-%dT%H:%M:%S.%fZ\")\n            if event.action == 'mandate_replaced':\n                mandate.write({\n                    'gc_mandate_id': event.links.new_mandate,\n                    'gc_last_state_change': eventDate\n                })                \n                return\n\n            if (mandate.gc_state != event.action) and (eventDate > fields.Datetime.from_string(mandate.gc_last_state_change)):     \n                # let's check we actually need to update something (disabled for debug)\n                mandate.write({\n                    'gc_state': event.action,\n                    'gc_last_state_change': eventDate\n                })\n                msg = \"GoCardless: Mandate ID {} changed state to {}\".format(mandate.gc_mandate_id,mandate.gc_state)\n                mandate.partner_id.message_post(body=msg)\n            #endif\n        #rof\n\n                        \n\n\nclass GC_Partner(models.Model):\n    _inherit = 'res.partner'\n\n    # use_gc      = fields.Boolean(\"Use GoCardless to collect payments?\", default=False)\n    use_gc      = fields.Boolean(compute='_compute_use_gc', store=False)\n\n    @api.depends('gc_state')\n    def _compute_use_gc(self):\n        for rec in self:\n            rec.use_gc = (rec.gc_state in ['pending', 'complete'])\n\n    gc_state    = fields.Selection(\n        [\n            ['setup','Awaiting Setup'],\n            ['pending','Pending'],\n            ['complete','Setup Complete']\n        ], \n        string=\"GoCardless setup state:\",        \n        default='setup'\n    )\n\n    gc_mandate_state    = fields.Selection(related='mandate_id.gc_state')\n\n    gc_last_state_change = fields.Date(\"Last updated\", default=datetime.date(year=1970,month=1,day=1))\n\n    gc_mandate_id       = fields.Char(\"GoCardless Mandate ID\", related='mandate_id.gc_mandate_id', store=False)\n    gc_redirect_flow_id = fields.Char()\n    gc_redirect_url     = fields.Char()\n\n    gc_access_token     = fields.Char()\n\n    mandate_id          = fields.Many2one(\n        comodel_name='gocardless.mandate',\n        string=\"GoCardless Mandate\")\n\n\n    \n    def action_send_partner_email(self):\n        self.send_partner_email(self)\n        # self.write({\n        #     'use_gc':    True\n        # })\n\n    def send_partner_email(self, partner, batch_run = False):\n        ICPSudo = self.env['ir.config_parameter'].sudo()\n\n        proceed = (ICPSudo.get_param('gocardless.gc_access_token') not in ['', False, None])\n\n        if not proceed:\n            raise exceptions.UserError(\n                \"Connect to your GoCardless account first!\"\n            )\n\n        gc_url = ICPSudo.get_param('gocardless.gc_custom_domain')\n        \n        base_url = ICPSudo.get_param('web.base.url') # default: use Odoo base URL\n        \n        # check sanity of our custom domain setting - if it passes, use that.\n        # because we've already set the Odoo base URL it'll fall back if one of these fails\n        if type(gc_url) is str:\n            if urls.url_parse(url=gc_url).scheme in ['http', 'https']:\n                base_url = gc_url\n            #endif\n        #endif\n\n        _logger.debug(\"Got something to do: {}\".format(partner.name))\n        count = partner.invoice_ids.search_count([('partner_id','=',partner.id),('state','!=','draft')])\n        if count <= 0 and batch_run:\n            return\n        #endif\n\n        gc_token = str(uuid.uuid4())\n        redirect_url = urls.url_join(base_url, '/gocardless/activate/?gc_access_token={}'.format(gc_token))\n        partner.write({\n            'gc_state': 'pending',\n            'gc_last_state_change': datetime.date.today(), \n            'gc_redirect_url': redirect_url,\n            'gc_access_token': gc_token\n        })\n        \n        # issue the email invite\n        mail_template = self.env.ref('gocardless.gc_mandate_invite_email')\n        self.env['mail.template'].browse(mail_template.id).send_mail(partner.id)\n\n    \n    \n    def addPartnerBatchRun(self):\n\n        date_last_week = datetime.date.today() - datetime.timedelta(days=7)\n        for partner in self.search([('gc_state', 'in', ['pending', 'complete']),\n                '|',\n                ('gc_state','=','setup'),\n                '&',\n                ('gc_state','=','pending'),\n                ('gc_last_state_change','<',date_last_week), # resubmit stale requests\n            ]):\n            self.send_partner_email(partner, batch_run=True)\n\n        #endfor\n    #end addPartnerBatchRun\n\n#end Partner\n\n\n\nclass ResConfigSettings(models.TransientModel):\n    \n    _inherit = 'res.config.settings'\n\n    gc_access_token     = fields.Char(\"Access Token\")  \n\n    gc_environment      = fields.Selection([['sandbox','Sandbox'],['live','Live']], \"API environment\", default='sandbox')\n    gc_description      = fields.Char(\"Description (to be shown on the GoCardless mandate page)\")\n    gc_webhook_secret   = fields.Char(\"Secret (Optional, for verification of GoCardless callbacks)\")\n    gc_webhook_url      = fields.Char(\"Webhook return URL\")\n\n    gc_custom_domain    = fields.Char(\"Custom URL prefix (leave blank to use the default Odoo URL)\")\n\n    gc_keep_journal     = fields.Boolean(\"Record GoCardless payments in an accounting journal?\", default=False)\n\n    \n    def gocardless_connect(self):\n        self.set_values()\n        return {\n            'type': 'ir.actions.act_url',\n            'url': '/gocardless/oauth-begin',\n            'target': 'self',\n        }\n\n    \n    def do_full_event_refresh(self):\n        return self.env['gocardless.event'].do_full_event_refresh()\n\n    \n    def get_default_journal(self):\n        return self.env.ref('gocardless.journal_gocardless').id\n\n    \n    def get_journals_selection(self):\n        ret = []\n        for j in self.env['account.journal']:\n            ret.append([j.id, j.name])\n        return ret\n\n    gc_journal_id       = fields.Many2one(comodel_name='account.journal',string=\"Journal to record payments in\")\n    \n    @api.model\n    def get_values(self):\n        res = super(ResConfigSettings, self).get_values()\n        ICPSudo = self.env['ir.config_parameter'].sudo()\n\n        jid = ICPSudo.get_param('gocardless.gc_journal_id')\n\n        kj = ICPSudo.get_param('gocardless.gc_keep_journal')\n\n        res.update(       \n            gc_access_token = ICPSudo.get_param('gocardless.gc_access_token'),\n            gc_environment = ICPSudo.get_param('gocardless.gc_environment'),\n            gc_description = ICPSudo.get_param('gocardless.gc_description'),\n            gc_webhook_secret = ICPSudo.get_param('gocardless.gc_webhook_secret'),\n            gc_webhook_url = urls.url_join(ICPSudo.get_param('web.base.url'),'/gocardless/webhook/'),\n            gc_custom_domain = ICPSudo.get_param('gocardless.gc_custom_domain'),\n            gc_keep_journal = kj,\n            gc_journal_id = int(jid) or False\n        )\n        return res\n    #end get_values\n\n    \n    def set_values(self):\n        super(ResConfigSettings, self).set_values()\n        ICPSudo = self.env['ir.config_parameter'].sudo()\n        ICPSudo.set_param('gocardless.gc_access_token', self.gc_access_token)\n        ICPSudo.set_param('gocardless.gc_environment', self.gc_environment)\n        ICPSudo.set_param('gocardless.gc_description', self.gc_description)\n        ICPSudo.set_param('gocardless.gc_webhook_secret', self.gc_webhook_secret)\n        ICPSudo.set_param('gocardless.gc_custom_domain', self.gc_custom_domain)\n        ICPSudo.set_param('gocardless.gc_keep_journal', self.gc_keep_journal)\n        ICPSudo.set_param('gocardless.gc_journal_id', int(self.gc_journal_id.id))\n    #end set_values\n\n\n#end ResConfigSettings\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\models\\__init__.py\nNome: __init__.py\n----------------------------------------\n# -*- coding: utf-8 -*-\n\nfrom . import models\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\security\\ir.model.access.csv\nNome: ir.model.access.csv\n----------------------------------------\nid,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink\naccess_gocardless_payment,GoCardless Payment Access,model_gocardless_payment,account.group_account_invoice,1,0,0,0\naccess_gocardless_mandate,GoCardless Payment Access,model_gocardless_mandate,account.group_account_invoice,1,1,1,0\naccess_gocardless_event,GoCardless Payment Access,model_gocardless_event,account.group_account_invoice,1,0,0,0\n\naccess_gocardless_wizard,GoCardless Payment Access,model_gocardless_charge_wizard,account.group_account_invoice,1,1,1,0\n\nadmin_access_gocardless_payment,GoCardless Payment System Access,model_gocardless_payment,base.group_system,1,0,0,0\nadmin_access_gocardless_mandate,GoCardless Payment System Access,model_gocardless_mandate,base.group_system,1,1,1,0\nadmin_access_gocardless_event,GoCardless Payment System Access,model_gocardless_event,base.group_system,1,0,0,0\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\static\\description\\index.html\nNome: index.html\n----------------------------------------\n<section class=\"oe_container\">\n    <div class=\"oe_row oe_spaced\">\n        <h2 class=\"oe_slogan oe_mb32\" style=\"color: #069;\">Now with default support for GoCardless Success+</h2>\n        <h3 class=\"oe_slogan oe_mb32\">Eligible payments will be retried automatically - no action required</h3>\n    </div>\n    <div class=\"oe_row text-center\">\n        <img src=\"gc-spot.png\" />\n    </div>\n    <div class=\"oe_row oe_spaced\">\n        <h2 class=\"oe_slogan\" style=\"color:#369;\">Three <b>currencies</b>. Two <b>continents</b>. One <b>click</b>.</h2>\n        <h3 class=\"oe_slogan oe_mb32\">Take payments in the <b>US, UK,</b> and <b>Europe</b> in one system</h3>\n        <div class=\"oe_span4 text-center\">\n            <span class=\"fa fa-money fa-5x\" style=\"color:#369;\" />\n            <h3 class=\"oe_slogan\" style=\"color: #369;\">Get paid on time</h3>\n            <p class=\"oe_mt16\">\n            Take online payment quickly and easily from your customers by direct debit\n            </p>\n        </div>\n        <div class=\"oe_span4 text-center\">\n            <span class=\"fa fa-gavel fa-5x\" style=\"color:#369;\" />\n            <h3 class=\"oe_slogan\" style=\"color: #369;\">Stay compliant</h3>\n            <p class=\"oe_mt16\">\n            No need to handle customers' bank details means no extra compliance burden\n            </p>\n        </div>\n        <div class=\"oe_span4 text-center\">\n            <span class=\"fa fa-repeat fa-5x\" style=\"color:#369;\" />\n            <h3 class=\"oe_slogan\" style=\"color: #369;\">Stay efficient</h3>\n            <p class=\"oe_mt16\">\n            Take subsequent direct debits simply by issuing an invoice\n            </p>\n        </div>\n    </div>\n</section>\n\n<section class=\"oe_container oe_dark\">\n    <div class=\"oe_row oe_spaced\">\n        <h2 class=\"oe_slogan\" style=\"color:#369;\">Taking payments just got easier</h2>\n        <h3 class=\"oe_slogan\">Simplify your billing workflow</h3>\n        <p class=\"oe_mt32\" style=\"text-align: justify;text-align-last: center;\">\n            Collect payments, invite new customers and set up Direct Debit mandates with the touch of a button\n        </p>\n    </div>\n    <div class=\"oe_row oe_spaced\">\n        <h2 class=\"oe_slogan\" style=\"color: #369;\">Stay informed</h2>\n        <h3 class=\"oe_slogan\">Track the status of pending direct debit payments from within Odoo</h3>\n        <p class=\"oe_mt32\" style=\"text-align: justify;text-align-last: center;\">\n            The GoCardless pane on the invoice information provides a comprehensive look at the current status of the invoice's GoCardless payments\n        </p>\n        <div class=\"oe_row_img oe_centered oe_mt32\">\n            <img style=\"margin-left: 12.5%; width: 75%;\" src=\"scr2.png\">\n        </div>\n    </div>\n</section>\n\n<section class=\"oe_container\">\n    <div class=\"oe_row oe_spaced\">\n       <h2 class=\"oe_slogan\" style=\"color:#369;\">Fully integrated accounting</h2>\n       <h3 class=\"oe_slogan\">Post payments to a dedicated journal &mdash; or update an existing one</h3>\n        <p class=\"oe_mt32\" style=\"text-align: justify;text-align-last: center;\">\n        J&ouml;tnar Systems has provided full support for Odoo's in-built accounting features. The GoCardless connector will keep track of the progress of pending payments, and can post confirmed payments to a dedicated journal &mdash; or update an existing journal of your choice. Related invoice statuses will update automatically.\n        </p>\n        <div class=\"oe_row_img oe_centered oe_mt32\">\n            <img class=\"oe_picture oe_screenshot\" src=\"scr3.png\">\n        </div>\n    </div>\n</section>\n\n<section class=\"oe_container\">\n    <div class=\"oe_row oe_spaced\">\n        <h2 class=\"oe_slogan\" style=\"color:#369;\">Simple setup</h2>\n        <h3 class=\"oe_slogan\">Easy configuration via Odoo settings</h3>\n        <p class=\"oe_mt32\" style=\"text-align: justify;text-align-last: center;\">\n        Concise, straightforward settings page enables you to turn the key and go &mdash; simply select your environment, press Connect and follow the prompts. That's it.\n        </p>\n        <div class=\"oe_row_img oe_centered oe_mt32\">\n            <img class=\"oe_picture oe_screenshot\" src=\"scr4.png\">\n        </div>\n    </div>\n</section>\n<section class=\"oe_container\">\n    <div class=\"oe_row\">\n        <div class=\"oe_span6 text-center\" style=\"min-height: 128px;\">\n            <img class=\"oe_picture\" src=\"gocardless.png\" style=\"margin-top: 25%; margin-left: 25%;\" />\n        </div>\n        <div class=\"oe_span6 text-center\">\n            <a href=\"https://www.jotnarsystems.com/odoo-erp\" target=\"_blank\">    \n                <img class=\"oe_picture\" src=\"jotnar.png\" alt=\"Jotnar Systems\" title=\"Jotnar Systems\" />\n            </a>\n        </div>        \n    </div>\n</section>\n\n<section class=\"oe_container\">\n    <div class=\"oe_row oe_spaced\">\n        <h2 class=\"oe_slogan\" style=\"color: #369;\">Important information</h2>\n        <p class=\"oe_mt32\" style=\"text-align: justify;\">\n            This application will charge a 1% fee per transaction via GoCardless. This fee covers our costs of maintaining and supporting the application, and is how we get paid for our work. Please note that interfering with the code to circumvent this fee will result in zero support being given.\n        </p>\n        <p class=\"oe_mt32\" style=\"text-align: justify;\">\n            Requires creation of a free account with GoCardless. This application transmits the following data to GoCardless Ltd for the purpose of setting up a Direct Debit mandate and taking payments: \n            Customer email address, invoice number, invoice amount. None of your customers' information is shared with J&ouml;tnar Systems at any time. For more information view our <a href=\"https://www.jotnarsystems.com/privacy-policy\">Privacy Policy.</a>\n        </p>\n        <p class=\"oe_mt32\" style=\"text-align: justify; font-weight: bold; color: #933;\">\n            Please note: This add-on is provided for convenience only. At no time will J&ouml;tnar Systems be held liable for any payment collected in error through use of this add-on, even in the case of malfunction.\n            It is the user's own responsibility to ensure that payments submitted to GoCardless are valid and due for collection, and that any payment submitted in error is properly cancelled within the GoCardless website itself.\n        </p>\n    </div>\n</section>\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\views\\templates.xml\nNome: templates.xml\n----------------------------------------\n<odoo>\n    <data>\n        <!-- <template id=\"listing\"> -->\n        <!--   <ul> -->\n        <!--     <li t-foreach=\"objects\" t-as=\"object\"> -->\n        <!--       <a t-attf-href=\"#{ root }/objects/#{ object.id }\"> -->\n        <!--         <t t-esc=\"object.display_name\"/> -->\n        <!--       </a> -->\n        <!--     </li> -->\n        <!--   </ul> -->\n        <!-- </template> -->\n        <!-- <template id=\"object\"> -->\n        <!--   <h1><t t-esc=\"object.display_name\"/></h1> -->\n        <!--   <dl> -->\n        <!--     <t t-foreach=\"object._fields\" t-as=\"field\"> -->\n        <!--       <dt><t t-esc=\"field\"/></dt> -->\n        <!--       <dd><t t-esc=\"object[field]\"/></dd> -->\n        <!--     </t> -->\n        <!--   </dl> -->\n        <!-- </template> -->\n    </data>\n</odoo>\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\views\\ui.xml\nNome: ui.xml\n----------------------------------------\n<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<odoo>\n    <record id=\"mandates_action\" model=\"ir.actions.act_window\">\n        <field name=\"name\">GoCardless Mandates</field>\n        <field name=\"view_mode\">tree,form</field>\n        <field name=\"target\">current</field>\n        <field name=\"res_model\">gocardless.mandate</field>\n        <field name=\"help\" type=\"html\">\n            <p class=\"oe_view_nocontent_create\">\n                No mandates currently exist!\n            </p></field>\n    </record>\n    <record id=\"gocardless_mandates_view_tree\" model=\"ir.ui.view\">\n        <field name=\"name\">GoCardless Mandates</field>\n        <field name=\"model\">gocardless.mandate</field>\n        <field name=\"arch\" type=\"xml\">\n            <tree default_order=\"gc_mandate_id desc\" delete=\"false\" string=\"Mandates\">\n                <field name=\"gc_mandate_id\"/>\n                <field name=\"gc_state\"/>\n                <field name=\"gc_last_state_change\"/>\n                <field name=\"partner_id\"/>\n            </tree></field>\n    </record>\n    <record id=\"gocardless_mandates_view_form\" model=\"ir.ui.view\">\n        <field name=\"name\">GoCardless Mandate</field>\n        <field name=\"model\">gocardless.mandate</field>\n        <field name=\"arch\" type=\"xml\">\n            <form>\n                <sheet>\n                    <field invisible=\"1\" name=\"id\"/>\n                    <div invisible=\"id != False\">\n                        <h1>\n                            Create Mandate\n                        </h1>\n                        <p>\n                            <b>\n                                Please note:\n                            </b>\n                            this form is intended to allow the manual entry of existing GoCardless mandates\n          which have been created elsewhere. It is your responsibility to make sure that details entered here\n          are correct - entering incorrect details may cause the integration to behave unexpectedly.\n                        </p>\n                        <separator/>\n                    </div>\n                    <group col=\"4\" string=\"Mandate\">\n                        <field name=\"gc_mandate_id\" readonly=\"id != False\"/>\n                        <field name=\"gc_state\" readonly=\"id != False\"/>\n                        <field name=\"gc_last_state_change\" readonly=\"1\"/>\n                        <field name=\"partner_id\" readonly=\"0\"/>\n                    </group>\n                    <div invisible=\"id == False\">\n                        <separator/>\n                        <field name=\"event_ids\"/>\n                    </div>\n                </sheet>\n            </form></field>\n    </record>\n    <record id=\"payments_action\" model=\"ir.actions.act_window\">\n        <field name=\"name\">GoCardless Payments</field>\n        <field name=\"view_mode\">tree,form</field>\n        <field name=\"target\">current</field>\n        <field name=\"res_model\">gocardless.payment</field>\n    </record>\n    <record id=\"payments_pop_action\" model=\"ir.actions.act_window\">\n        <field name=\"name\">GoCardless Payments</field>\n        <field name=\"view_mode\">form</field>\n        <field name=\"target\">new</field>\n        <field name=\"res_model\">gocardless.payment</field>\n    </record>\n    <record id=\"gocardless_payments_view_tree\" model=\"ir.ui.view\">\n        <field name=\"name\">GoCardless Payments</field>\n        <field name=\"model\">gocardless.payment</field>\n        <field name=\"arch\" type=\"xml\">\n            <tree create=\"false\" default_order=\"gc_payment_id desc\" delete=\"false\">\n                <field name=\"claim_date\"/>\n                <field name=\"gc_payment_id\"/>\n                <field name=\"gc_payment_state\"/>\n                <field name=\"post_date\"/>\n                <field name=\"payout_date\"/>\n            </tree></field>\n    </record>\n    <record id=\"gocardless_payments_view_form\" model=\"ir.ui.view\">\n        <field name=\"name\">GoCardless Payments</field>\n        <field name=\"model\">gocardless.payment</field>\n        <field name=\"arch\" type=\"xml\">\n            <form create=\"false\" edit=\"false\">\n                <sheet>\n                    <header>\n                        <button confirm=\"Are you sure you want to cancel this payment?\" groups=\"account.group_account_manager\" invisible=\"gc_payment_state not in ['pending', 'created']\" name=\"gc_cancel_payment\" string=\"Cancel Payment\" type=\"object\"/>\n                    </header>\n                    <group col=\"4\" string=\"Payment\">\n                        <field name=\"gc_payment_id\" readonly=\"1\"/>\n                        <field name=\"gc_payment_state\" readonly=\"1\"/>\n                        <field name=\"amount\" readonly=\"1\"/>\n                        <field name=\"claim_date\" readonly=\"1\"/>\n                        <field name=\"post_date\" readonly=\"1\"/>\n                        <field name=\"payout_date\" readonly=\"1\"/>\n                        <field name=\"invoice_id\" readonly=\"1\"/>\n                    </group>\n                    <separator/>\n                    <field name=\"event_ids\"/>\n                </sheet>\n            </form></field>\n    </record>\n    <record id=\"events_action\" model=\"ir.actions.act_window\">\n        <field name=\"name\">GoCardless Events</field>\n        <field name=\"view_mode\">tree,form</field>\n        <field name=\"target\">current</field>\n        <field name=\"res_model\">gocardless.event</field>\n    </record>\n    <record id=\"gocardless_events_view_tree\" model=\"ir.ui.view\">\n        <field name=\"name\">GoCardless Events</field>\n        <field name=\"model\">gocardless.event</field>\n        <field name=\"arch\" type=\"xml\">\n            <tree create=\"false\" default_order=\"created_at desc\" delete=\"false\">\n                <field name=\"created_at\"/>\n                <field name=\"event_id\"/>\n                <field name=\"resource_type\"/>\n                <field name=\"action\"/>\n                <field name=\"cause\"/>\n                <field name=\"ev_origin\"/>\n                <field invisible=\"mandate_id == False\" name=\"mandate_id\"/>\n                <field invisible=\"payment_id == False\" name=\"payment_id\"/>\n            </tree></field>\n    </record>\n    <record id=\"gocardless_events_view_form\" model=\"ir.ui.view\">\n        <field name=\"name\">GoCardless Events</field>\n        <field name=\"model\">gocardless.event</field>\n        <field name=\"arch\" type=\"xml\">\n            <form create=\"false\" edit=\"false\">\n                <sheet>\n                    <group col=\"4\" string=\"Event\">\n                        <field name=\"created_at\" readonly=\"1\"/>\n                        <field name=\"event_id\" readonly=\"1\"/>\n                        <field name=\"resource_type\" readonly=\"1\"/>\n                        <field name=\"action\" readonly=\"1\"/>\n                        <field name=\"cause\" readonly=\"1\"/>\n                        <field name=\"ev_description\" readonly=\"1\"/>\n                        <field name=\"ev_origin\" readonly=\"1\"/>\n                        <field invisible=\"mandate_id == False\" name=\"mandate_id\" readonly=\"1\"/>\n                        <field invisible=\"payment_id == False\" name=\"payment_id\" readonly=\"1\"/>\n                    </group>\n                </sheet>\n            </form></field>\n    </record>\n    <menuitem groups=\"account.group_account_manager\" id=\"menu_gocardless_main\" name=\"GoCardless\" web_icon=\"gocardless,static/description/icon.png\"/>\n    <menuitem id=\"menu_gocardless\" name=\"GoCardless - Main Menu\" parent=\"menu_gocardless_main\"/>\n    <menuitem action=\"mandates_action\" id=\"mandates_menu\" name=\"Mandates\" parent=\"menu_gocardless\"/>\n    <menuitem action=\"payments_action\" id=\"payments_menu\" name=\"Payments\" parent=\"menu_gocardless\"/>\n    <menuitem action=\"events_action\" id=\"events_menu\" name=\"Events\" parent=\"menu_gocardless\"/>\n</odoo>\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\views\\views.xml\nNome: views.xml\n----------------------------------------\n<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<odoo>\n    <record id=\"gocardless_invoice_tree\" model=\"ir.ui.view\">\n        <field name=\"name\">account.invoice.tree.gocardless</field>\n        <field name=\"model\">account.move</field>\n        <field name=\"inherit_id\" ref=\"account.view_invoice_tree\"/>\n        <field name=\"arch\" type=\"xml\">\n            <field name=\"state\" position=\"before\">\n                <field name=\"gc_payment_attempted\" readonly=\"1\"/></field></field>\n    </record>\n    <record id=\"gocardless_invoice_view\" model=\"ir.ui.view\">\n        <field name=\"name\">account.move.form.gocardless</field>\n        <field name=\"model\">account.move</field>\n        <field name=\"inherit_id\" ref=\"account.view_move_form\"/>\n        <field name=\"arch\" type=\"xml\">\n            <header position=\"inside\">\n                <field invisible=\"1\" name=\"gc_display_gc\"/>\n                <field invisible=\"1\" name=\"gc_payment_attempted\"/>\n                <field invisible=\"1\" name=\"gc_enable_payment_recreate\"/>\n                <field invisible=\"1\" name=\"payment_state\"/>\n                <button class=\"oe_highlight\" groups=\"account.group_account_invoice\" invisible=\"gc_display_gc == False or state not in 'posted' or payment_state not in 'not_paid' or gc_payment_attempted == True\" name=\"action_gocardless_take_payment\" string=\"Take Payment by GoCardless\" type=\"object\"/>\n                <button groups=\"account.group_account_invoice\" invisible=\"gc_display_gc == False or state not in 'posted' or payment_state not in 'not_paid' or gc_payment_attempted == False\" name=\"action_gocardless_retry_payment\" string=\"Retry GoCardless Payment\" type=\"object\"/>\n                <button confirm=\"You are about to attempt an entirely new payment. This should ONLY be done if the original mandate failed, and a new mandate has been set up. Misuse of this feature may result in double charging. Do you wish to continue?\" groups=\"account.group_account_manager\" invisible=\"gc_display_gc == False or state not in 'posted' or payment_state not in 'not_paid' or gc_payment_attempted == False or gc_enable_payment_recreate == False\" name=\"action_gocardless_recreate_payment\" string=\"Recreate GoCardless Payment\" type=\"object\"/>\n            </header>\n            <notebook position=\"inside\">\n                <page invisible=\"state in ['draft']\" string=\"GoCardless\">\n                    <h2>\n                        GoCardless\n                    </h2>\n                    <div invisible=\"gc_display_gc == False\">\n                        <div class=\"row mt16\">\n                            <div class=\"col-md-6 col-xs-12\">\n                                <h3 modifiers=\"{}\">\n                                    Payment Info\n                                </h3>\n                                <label for=\"gc_last_payment_attempt\"/>\n                                <field name=\"gc_last_payment_attempt\" readonly=\"1\"/>\n                            </div>\n                        </div>\n                        <div class=\"row mt16\">\n                            <div class=\"col-md-12 col-xs-12\" invisible=\"state in ['draft']\">\n                                <h3 modifiers=\"{}\">\n                                    Payments\n                                </h3>\n                                <group>\n                                    <field name=\"gc_payments\"><tree create=\"false\" delete=\"false\" edit=\"false\">\n                                            <field name=\"claim_date\"/>\n                                            <field name=\"gc_payment_id\"/>\n                                            <field name=\"gc_payment_state\"/>\n                                            <field name=\"post_date\"/>\n                                            <field name=\"payout_date\"/>\n                                        </tree></field>\n                                </group>\n                            </div>\n                        </div>\n                    </div>\n                    <div invisible=\"gc_display_gc == True\">\n                        <div class=\"row mt16\">\n                            <div class=\"col-md-12 col xs-12\">\n                                <h3>\n                                    GoCardless is not available for this partner\n                                </h3>\n                                <p>\n                                    Ensure GoCardless is enabled on this partner's record, and that their status is 'Confirmed'\n                                </p>\n                            </div>\n                        </div>\n                    </div>\n                </page>\n            </notebook></field>\n    </record>\n    <record id=\"gocardless_partner_view\" model=\"ir.ui.view\">\n        <field name=\"name\">res.partner.gocardless</field>\n        <field name=\"model\">res.partner</field>\n        <field name=\"inherit_id\" ref=\"base.view_partner_form\"/>\n        <field name=\"arch\" type=\"xml\">\n            <notebook position=\"inside\">\n                <page groups=\"account.group_account_invoice\" string=\"GoCardless\">\n                    <field invisible=\"1\" name=\"use_gc\"/>\n                    <div class=\"row mt16\">\n                        <div class=\"col-xs-12 col-md-6\">\n                            <group string=\"GoCardless Information\">\n                                <field name=\"gc_state\" readonly=\"1\"/>\n                                <field name=\"mandate_id\" readonly=\"1\"/>\n                            </group>\n                            <button class=\"oe_highlight\" groups=\"account.group_account_invoice\" invisible=\"gc_state not in ['setup']\" name=\"action_send_partner_email\" string=\"Send Setup Email\" type=\"object\"/>\n                            <button confirm=\"Are you sure you want to resend the setup email?\" groups=\"account.group_account_invoice\" invisible=\"gc_state not in ['pending']\" name=\"action_send_partner_email\" string=\"Resend Setup Email\" type=\"object\"/>\n                            <button confirm=\"Are you sure you want to restart the setup process? (This will disable GoCardless payments for this partner until they respond)\" groups=\"account.group_account_manager\" invisible=\"gc_state not in ['complete']\" name=\"action_send_partner_email\" string=\"Recreate Mandate\" type=\"object\"/>\n                        </div>\n                    </div>\n                    <br/>\n                </page>\n            </notebook></field>\n    </record>\n    <record id=\"config_settings_view_gocardless\" model=\"ir.ui.view\">\n        <field name=\"name\">res.config.settings.view.form.inherit.gocardless</field>\n        <field name=\"model\">res.config.settings</field>\n        <field name=\"inherit_id\" ref=\"base.res_config_settings_view_form\"/>\n        <field name=\"arch\" type=\"xml\">\n            <xpath expr=\"//form\" position=\"inside\">\n                <app name=\"gocardless\" data-string=\"GoCardless\" string=\"GoCardless\">\n                    <div style=\"padding-top: 1rem;\">\n                        <h1 style=\"padding-left: 1rem;\">\n                            GoCardless Integration\n                        </h1>\n                        <div class=\"row mt16\">\n                            <div class=\"col-xs-12 col-md-6\">\n                                <block title=\"Connection\">\n                                    <setting invisible=\"gc_access_token in ['', False, None]\">\n                                        <field name=\"gc_access_token\" readonly=\"1\"/>\n                                    </setting>\n                                    <setting help=\"Choose between the Live and Sandbox environments. Use Live when you are ready to take real payments.\">\n                                        <field name=\"gc_environment\"/>\n                                    </setting>\n                                </block>\n                                <block col=\"1\">\n                                    <!-- <button class=\"oe_highlight\" type=\"object\" name=\"gocardless_disconnect\" string=\"Disconnect from GoCardless\" attrs=\"{'invisible':[('gc_access_token','in',['',False,None])]}\" /> -->\n                                    <setting>\n                                        <button class=\"oe_highlight\" invisible=\"gc_access_token not in ['', False, None]\" name=\"gocardless_connect\" string=\"Connect to GoCardless\" type=\"object\"/>\n                                        <button invisible=\"gc_access_token in ['', False, None]\" name=\"gocardless_connect\" string=\"Reconnect to GoCardless\" type=\"object\"/>\n                                    </setting>\n                                </block>\n                                <block title=\"General Settings\">\n                                    <setting help=\"This is the description which will appear at the top of the GoCardless customer forms.\">\n                                        <field name=\"gc_description\"/>\n                                        <p>\n                                            <b>\n                                                Please note: Odoo must be accessible from the outside world in order for the GoCardless mandate setup to work!\n                                            </b>\n                                        </p>\n                                    </setting>\n                                    <setting help=\"This is the URL given to customers in the GoCardless invite email. You can override the default by specifying a top-level URL here (e.g. https://odoo.contoso.com).\">\n                                        <field name=\"gc_custom_domain\"/>\n                                        <p>\n                                            <b>\n                                                Odoo\n                                                <u>\n                                                    must\n                                                </u>\n                                                be accessible via the domain you enter here, otherwise customers will not be able to complete the GoCardless setup flow! If in any doubt, leave this field blank to use Odoo's usual access URL.\n                                            </b>\n                                        </p>\n                                    </setting>\n                                </block>\n                            </div>\n                            <div class=\"col-xs-12 col-md-6\">\n                                <block title=\"Journaling\">\n                                    <setting>\n                                        <field name=\"gc_keep_journal\"/>\n                                    </setting>\n                                    <setting help=\"This journal should be of type 'Bank' in order to function as intended\">\n                                        <field name=\"gc_journal_id\" options=\"{'no_quick_create': True,'no_create_edit':True}\"/>\n                                    </setting>\n                                </block>\n                                <block col=\"4\" title=\"Maintenance\">\n                                    <setting groups=\"base.group_system\" invisible=\"gc_access_token in ['', False, None]\">\n                                        <p>Intended for debugging purposes only. Please do not touch unless directed to by J\u00f6tnar Systems support staff</p>\n                                        <button confirm=\"This will re-scan your GoCardless account for up to the last 500 events from all time.                                         This may take some time. Are you sure you wish to continue?\" name=\"do_full_event_refresh\" string=\"Refresh All Events\" type=\"object\"/>\n                                    </setting>\n                                </block>\n                                <block title=\"Help &amp; Support\">\n                                    <p>\n                                        For more information, please visit\n                                        <a href=\"https://www.jotnarsystems.com\">\n                                            J\u00f6tnar Systems.\n                                        </a>\n                                    </p>\n                                    <p/>\n                                    <p>\n                                        For technical support, please feel free to email\n                                        <a href=\"mailto:<PRESIDIO_ANONYMIZED_EMAIL_ADDRESS>\">\n                                            <PRESIDIO_ANONYMIZED_EMAIL_ADDRESS>\n                                        </a>\n                                    </p>\n                                </block>\n                            </div>\n                        </div>\n                    </div>\n                </app>\n            </xpath></field>\n    </record>\n    <record id=\"gocardless_settings_action\" model=\"ir.actions.act_window\">\n        <field name=\"name\">GoCardless Settings</field>\n        <field name=\"res_model\">res.config.settings</field>\n        <field name=\"view_id\" ref=\"config_settings_view_gocardless\"/>\n        <field name=\"view_mode\">form</field>\n        <field name=\"target\">inline</field>\n    </record>\n</odoo>\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\wizard\\wizard.py\nNome: wizard.py\n----------------------------------------\nfrom odoo import models, api, _\nfrom odoo.exceptions import UserError\n\n\nclass GocardlessSetupWizard(models.TransientModel):\n\n    _name = \"gocardless.setup.wizard\"\n    _description = \"Send mandate setup emails\"\n\n    def send_setup_email(self):\n        ctx = dict(self._context or {})\n\n        active_ids = ctx.get('active_ids', []) or []\n        for r in self.env['res.partner'].browse(active_ids):\n            if r.gc_state != 'setup':\n                # don't double bump, just skip over silently\n                continue\n\n            r.action_send_partner_email()\n\n\nclass GocardlessChargeWizard(models.TransientModel):\n\n    _name = \"gocardless.charge.wizard\"\n    _description = \"Take payments for invoices by GoCardless\"\n\n    def take_payment(self):\n        ctx = dict(self._context or {})\n\n        active_ids = ctx.get('active_ids', []) or []\n        for r in self.env['account.move'].browse(active_ids):\n            if (r.state != 'posted') or (r.payment_state != 'not_paid'):\n                raise UserError('Only open invoices can be charged. Please make sure you have not selected draft or paid invoices, and try again.')\n            if not r.gc_display_gc:\n                raise UserError('One or more selected invoices are not eligible for GoCardless (have all selected customers completed GoCardless setup?)')\n            if r.gc_payment_attempted:\n                # don't double bump the payment - although idempotency should\n                # protect the customer, this still results in a needless api call\n                continue\n\n            r.action_gocardless_take_payment()\n\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\wizard\\wizard.xml\nNome: wizard.xml\n----------------------------------------\n<odoo>\n    <record id=\"gocardless_charge_wizard_view\" model=\"ir.ui.view\">\n        <field name=\"name\">gocardless.charge.wizard.form</field>\n        <field name=\"model\">gocardless.charge.wizard</field>\n        <field name=\"arch\" type=\"xml\">\n            <form string=\"Confirm Draft Invoices\">\n                <p class=\"oe_grey\">\n                    This will attempt to take payments for all the selected invoices by GoCardless.\n                    Only open invoices can be charged, and if payment has already been attempted this action will not retry the payment(s).\n                    If you are ready to continue, click \"Take Payments\".\n                </p>\n                <footer>\n                    <button string=\"Take Payments\" name=\"take_payment\" type=\"object\" default_focus=\"1\" class=\"btn-primary\"/>\n                    <button string=\"Cancel\" class=\"btn-default\" special=\"cancel\"/>\n                </footer>\n            </form>\n        </field>\n    </record>\n\n    <record id=\"action_gocardless_charge_wizard\" model=\"ir.actions.act_window\">\n        <field name=\"name\">Take Payment by GoCardless</field>\n        <field name=\"res_model\">gocardless.charge.wizard</field>\n        <field name=\"binding_model_id\" ref=\"account.model_account_move\" />\n        <field name=\"view_mode\">form</field>\n        <field name=\"target\">new</field>\n    </record>\n\n<!-- <act_window\n            name=\"Send &amp; print\"\n            id=\"invoice_send\"\n            res_model=\"account.invoice.send\"\n            binding_model=\"account.move\"\n            binding_views=\"list\"\n            view_mode=\"form\"\n            target=\"new\"\n            context=\"{\n                'default_template_id': ref('account.email_template_edi_invoice'),\n                'mark_invoice_as_sent': True,\n            }\"\n            groups=\"account.group_account_invoice\"/>         -->\n\n</odoo>\n========================================\n\nPercorso: C:\\Users\\Utente\\Desktop\\gocardless_17\\gocardless\\wizard\\__init__.py\nNome: __init__.py\n----------------------------------------\nfrom . import wizard\n========================================"},{"assistant_initiates":false,"asst_text":"Il modulo descritto non sembra effettuare il recupero diretto delle transazioni bancarie. Si concentra principalmente sulla gestione dei mandati e dei pagamenti tramite addebito diretto utilizzando GoCardless. Infatti, il modulo \u00e8 progettato per creare e aggiornare i mandati e i pagamenti gestendo anche stati e notifiche associate, ma non c'\u00e8 evidenza nel codice che si occupi del recupero delle transazioni bancarie tradizionali (ad esempio, importare estratti conto direttamente dal sistema bancario).\n\nPer gestire le transazioni bancarie tradizionali in Odoo, si utilizzano strumenti diversi che generalmente richiedono l'uso di un modulo specifico per l'integrazione bancaria che consente di importare estratti conto in formato standard come CAMT o MT940, e che pu\u00f2 essere configurato per eseguire la riconciliazione bancaria automatica.","behavior":"degenerate_repetition","conversation_hash":"f95b9df18ac2c2bf6251e8388f7be6cf","conversation_redacted":true,"conversation_toxic":false,"country":"Italy","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"Italian","model":"gpt-4o-2024-08-06","n_chars":877,"n_turns_in_conversation":3,"n_words":122,"source_row_offset":30465,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:31 GMT","turn_id":"aec5eedb4ee2c42977910581","turn_index":1,"user_text":"recupera le transazioni bancarie?"},{"assistant_initiates":false,"asst_text":"Il modulo descritto consente effettivamente di gestire i pagamenti, ma questi pagamenti avvengono attraverso la piattaforma GoCardless e non tramite l'accesso diretto alle transazioni bancarie tradizionali.\n\n### Cosa Puoi Fare con Questo Modulo:\n1. **Creare Pagamenti:** \n   - \u00c8 possibile creare pagamenti per le fatture utilizzando il servizio di addebito diretto di GoCardless. Questo significa che puoi richiedere pagamenti direttamente dai conti bancari dei clienti se hai un mandato attivo.\n\n2. **Gestire lo Stato dei Pagamenti:** \n   - Il modulo tiene traccia dello stato dei pagamenti (es. in attesa, confermato, fallito) e aggiorna le informazioni di pagamento e le fatture in Odoo in base agli eventi notificati da GoCardless.\n\n3. **Automazione e Notifiche:** \n   - Gli eventi relativi ai pagamenti vengono registrati e notificati nel sistema, quindi ricevi aggiornamenti automatici sui cambiamenti di stato dei pagamenti, come quando un pagamento \u00e8 confermato.\n\n### Cosa Non Fa Questo Modulo:\n- Non recupera le transazioni bancarie tradizionali o gli estratti conto bancari direttamente dalla banca.\n- Non gestisce i pagamenti al di fuori di GoCardless o quelli che richiedono l'accesso diretto alle informazioni del conto bancario del cliente senza passare per la piattaforma di addebito diretto.\n\nPertanto, se la tua necessit\u00e0 \u00e8 quella di effettuare pagamenti ai fornitori o eseguire trasferimenti tradizionali tramite collegamenti diretti con la tua banca, avrai bisogno di un altro strumento o modulo che supporta questo tipo di transazioni.","behavior":"degenerate_repetition","conversation_hash":"f95b9df18ac2c2bf6251e8388f7be6cf","conversation_redacted":true,"conversation_toxic":false,"country":"Italy","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"Italian","model":"gpt-4o-2024-08-06","n_chars":1599,"n_turns_in_conversation":3,"n_words":235,"source_row_offset":30466,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:31 GMT","turn_id":"a5d00e9b7728d2d4ec117c35","turn_index":2,"user_text":"quindi nenache i pagamenti si possono fare?"},{"assistant_initiates":false,"asst_text":"Question: Success relies on officers and directors.\nlabel: Yes\n\nQuestion: Officers must commit specific time to company affairs.\nlabel: No\n\nQuestion: Officers have conflicts of interest.\nlabel: Yes\n\nQuestion: Losing directors is beneficial to the company.\nlabel: No\n\nQuestion: No employment agreement exists with officers.\nlabel: Yes\n\nQuestion: Key personnel loss affects post-combination business.\nlabel: Yes","behavior":"degenerate_repetition","conversation_hash":"9e277465adc5b82594dff771ee699eb8","conversation_redacted":false,"conversation_toxic":false,"country":"","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"English","model":"gpt-4o-2024-08-06","n_chars":2243,"n_turns_in_conversation":1,"n_words":347,"source_row_offset":30467,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:33 GMT","turn_id":"8e4f22833c4eac25d9455b18","turn_index":0,"user_text":"System: You are an expert Data Annotator. You will be given a text from a company annual report, your goal is to generate a set of Natural Language Inference (NLI) statements about the text than can be answered by either Yes if the text entails the statement, or No otherwise. Do not include any numerical reasoning or numbers in the statements.\n\nStep 1: Read the paragraph carefully. \nStep 2: For each relevant task you identify, generate two short statements that are shorter than 10 words \nStep 3: Output the results in the following format:\n\nQuestion: <The statement>\nlabel: <Yes or No>\nQuestion: <Another statement>\nlabel: <Yes or No>\n...\n\nUser: Our operations are dependent upon a relatively small group of individuals and, in particular, our officers and directors. We believe that our success depends on the continued service of our officers and directors, at least until we have completed our initial business combination. In addition, our officers and directors are not required to commit any specified amount of time to our affairs and, accordingly, have conflicts of interest in allocating their time among various business activities, including identifying potential business combinations and monitoring the related due diligence. We do not have an employment agreement with, or key-man insurance on the life of, any of our directors or officers. The unexpected loss of the services of one or more of our directors or officers could have a detrimental effect on us._Our ability to successfully effect our initial business combination and to be successful thereafter will be dependent upon the efforts of our key personnel, some of whom may join us following our initial business combination. The loss of key personnel could negatively impact the operations and profitability of our post-combination business._\nAssistant:"},{"assistant_initiates":false,"asst_text":"```json\n{\n    \"relevant_tasks\": [\n        {\n            \"task\": \"Event Detection\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph describes an event where the pharmaceutical industry's largest lobbying group and other organizations sued the Biden administration.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph describes an event where the pharmaceutical industry accepted new Medicare pricing rules under the Inflation Reduction Act.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        },\n        {\n            \"task\": \"Entity Recognition\",\n            \"examples\": [\n                {\n                    \"input\": \"Entities such as the Pharmaceutical Research and Manufacturers of America and the Biden administration are mentioned in the paragraph.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph mentions the World Health Organization as a key entity involved.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        },\n        {\n            \"task\": \"Sector Identification\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph is related to the pharmaceutical sector.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph is related to the automotive sector.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        },\n        {\n            \"task\": \"Impact Classification\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph implies a potential negative impact on the pharmaceutical industry due to the lawsuit against the Biden administration.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph suggests a positive impact on the pharmaceutical industry because of higher drug pricing for seniors.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        },\n        {\n            \"task\": \"Tense Identification\",\n            \"examples\": [\n                {\n                    \"input\": \"The paragraph primarily discusses events in the present.\",\n                    \"label\": \"entailment\"\n                },\n                {\n                    \"input\": \"The paragraph primarily discusses events in the future.\",\n                    \"label\": \"non-entailment\"\n                }\n            ]\n        }\n    ]\n}\n```","behavior":"degenerate_repetition","conversation_hash":"e938468239d4dc1f95f2e23881f6f8a8","conversation_redacted":false,"conversation_toxic":false,"country":"United States","empty_output":false,"evidence_codes":[],"label":"absent","label_present":false,"label_qualified":false,"label_source":"Final dense release","language":"English","model":"gpt-4o-2024-08-06","n_chars":4720,"n_turns_in_conversation":1,"n_words":499,"source_row_offset":30468,"source_shard":"turns-00040.parquet","timestamp":"Sun, 27 Oct 2024 19:06:35 GMT","turn_id":"93fd4a86333224c878b74d14","turn_index":0,"user_text":"System: You are provided with a paragraph. Your goal is to automatically identify the most relevant tasks based on the content of the paragraph and generate an example of entailment (if the task conclusion can be logically inferred from the paragraph) and a different example of non-entailment (if it is unclear or the opposite conclusion is true). \n\nStep 1: Read the paragraph carefully. \nStep 2: Automatically decide which tasks are relevant based on the paragraph\u2019s content. Relevant tasks may include, but are not limited to: \n    - Topic Classification \n    - Risk Classification\n    - Sentiment Classification \n    - Tone Classification\n    - Event Detection \n    - Entity Recognition \n    - Geographical Recognition \n    - Trend Detection \n    - Intent Detection \n    - Sector Identification \n    - Impact Classification \n    - Tense Identification (Past, Present, Future) \n    - Uncertainty Identification \n\nStep 3: For each relevant task you identify, generate two clear and concise examples whose labels match common practices for the task at hand: one for entailment and one for non-entailment. The example should speak about the text at the 3rd person. \nStep 4: Output the results in the following JSON format:\n\n{\n    'relevant_tasks': [\n        {\n            'task': <The automatically selected relevant task>,\n            'examples': [\n                {\n                    'input': <The entailment example based on the paragraph>,\n                    'label': 'entailment',\n                },\n                {\n                    'input': <The non-entailment example (neutral or contradiction) based on the paragraph>,\n                    'label': 'non-entailment',\n                }\n            ]\n        },\n        ...\n    ]\n}\nUser:   The pharmaceutical industry's largest lobbying group and two other organizations sued the Biden administration over Medicare's new powers to slash drug prices for seniors under the Inflation Reduction Act.\u00a0 Pharmaceutical Research and Manufacturers of America, the National Infusion Center Associat\nAssistant:"}],"shard":{"index":40,"name":"turns-00040.parquet","rows":45683}}
