Sets the project's contents You can use this to upload projects to the Scratch website. Returns a dict with Scratch's raw JSON API response. Args: project_body (scratchattach.ProjectBody): A ProjectBody object containing the contents of the project
(self, project_body: editor.Project)
| 369 | return self.raw_json()["meta"]["agent"] |
| 370 | |
| 371 | def set_body(self, project_body: editor.Project): |
| 372 | """ |
| 373 | Sets the project's contents You can use this to upload projects to the Scratch website. |
| 374 | Returns a dict with Scratch's raw JSON API response. |
| 375 | |
| 376 | Args: |
| 377 | project_body (scratchattach.ProjectBody): A ProjectBody object containing the contents of the project |
| 378 | """ |
| 379 | self._assert_permission() |
| 380 | |
| 381 | return self.set_json(project_body.to_json()) |
| 382 | |
| 383 | def set_json(self, json_data): |
| 384 | """ |
nothing calls this directly
no test coverage detected