setProjectSettingsDocument method
Implementation
Future<void> setProjectSettingsDocument({required String projectId, required String name, required Map<String, dynamic> document}) async {
final encodedProjectId = Uri.encodeComponent(projectId);
final path = _projectSettingsDocumentPath(name);
final uri = Uri.parse('$baseUrl/accounts/projects/$encodedProjectId/settings/$path');
final response = await httpClient.put(uri, body: jsonEncode(document));
if (response.statusCode >= 400) {
throw MeshagentException(
'Failed to set project settings document. '
'Status code: ${response.statusCode}, body: ${response.body}',
);
}
}