{"record":{"id":"d893a673b6b9b90f","repo":"appsmithorg/appsmith","slug":"pe-arg-5000-d893a6","errorCode":"PE-ARG-5000","errorMessage":"Missing required field 'Spreadsheet Name'","messagePattern":"Missing required field 'Spreadsheet Name'","errorType":"exception","errorClass":"AppsmithPluginException","httpStatus":500,"severity":"error","filePath":"app/server/appsmith-plugins/googleSheetsPlugin/src/main/java/com/external/config/FileCreateMethod.java","lineNumber":51,"sourceCode":"import java.util.stream.StreamSupport;\n\n/**\n * API reference: https://developers.google.com/sheets/api/reference/rest/v4/spreadsheets/create\n */\n@Slf4j\npublic class FileCreateMethod implements ExecutionMethod {\n\n    ObjectMapper objectMapper;\n\n    public FileCreateMethod(ObjectMapper objectMapper) {\n        this.objectMapper = objectMapper;\n    }\n\n    @Override\n    public boolean validateExecutionMethodRequest(MethodConfig methodConfig) {\n        if (methodConfig.getSpreadsheetName() == null\n                || methodConfig.getSpreadsheetName().isBlank()) {\n            throw new AppsmithPluginException(\n                    AppsmithPluginError.PLUGIN_EXECUTE_ARGUMENT_ERROR,\n                    ErrorMessages.MISSING_SPREADSHEET_NAME_ERROR_MSG);\n        }\n        return true;\n    }\n\n    @Override\n    public WebClient.RequestHeadersSpec<?> getExecutionClient(WebClient webClient, MethodConfig methodConfig) {\n\n        Spreadsheet spreadsheet = new Spreadsheet();\n        spreadsheet.setProperties(new SpreadsheetProperties().set(\"title\", methodConfig.getSpreadsheetName()));\n        var ref = new Object() {\n            Integer startingRow = null;\n            Integer endingRow = null;\n            final Set<String> headers = new LinkedHashSet<>();\n            final Set<String> unknownHeaders = new LinkedHashSet<>();\n        };\n        final String body = methodConfig.getRowObjects();","sourceCodeStart":33,"sourceCodeEnd":69,"githubUrl":"https://github.com/appsmithorg/appsmith/blob/8cd9021c24cdbea1c3c12c966073708e83db60c2/app/server/appsmith-plugins/googleSheetsPlugin/src/main/java/com/external/config/FileCreateMethod.java#L33-L69","documentation":"FileCreateMethod.validateExecutionMethodRequest (FileCreateMethod.java:48-55) throws this when the spreadsheet name for the Create File operation is null or blank. The spreadsheet name becomes the title property of the newly created Spreadsheet object (line 62). Without a name, the Google Sheets API create request cannot proceed. Categorized as PLUGIN_EXECUTE_ARGUMENT_ERROR (PE-ARG-5000) with message 'Missing required field \\'Spreadsheet Name\\''.","triggerScenarios":"The Google Sheets 'Create Spreadsheet' (File Create) operation is executed but the 'Spreadsheet Name' field is empty, null, or whitespace-only. methodConfig.getSpreadsheetName() returns null or blank, failing the check at lines 49-50.","commonSituations":"1) User selects the Create File method but forgets to enter a name for the new spreadsheet. 2) JS binding for the spreadsheet name returns empty at runtime. 3) The name field was cleared after initial entry. 4) A dynamic name expression evaluates to an empty string due to a null reference in the binding.","solutions":["Enter a non-empty name for the new spreadsheet in the 'Spreadsheet Name' field.","If using JS bindings, ensure the expression returns a non-empty string, e.g. {{ 'Report_' + moment().format('YYYYMMDD') }}.","Provide a fallback in the binding to avoid empty values: {{ nameInput.text || 'Untitled Spreadsheet' }}.","Verify the name does not consist of only whitespace characters."],"exampleFix":"// before — Create File with empty name:\n// Spreadsheet Name: (empty)\n\n// after — provide a valid name:\n// Spreadsheet Name: {{ 'Sales Report ' + moment().format('YYYY-MM-DD') }}","handlingStrategy":"validation","validationCode":"// Validate spreadsheet name is non-empty before create operation\nif (!form.spreadsheetName || form.spreadsheetName.trim() === '') {\n  showAlert('Spreadsheet name is required to create a new spreadsheet', 'error');\n} else {\n  await sheetsCreateQuery.run();\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Always provide a non-empty name when creating a new spreadsheet.","Add a fallback in JS bindings: {{ nameInput.text || 'Untitled' }}.","Verify the name field is not whitespace-only."],"tags":["google-sheets","spreadsheet-name","validation","file-create","appsmith"],"backgroundTag":null,"analyzedSha":"8cd9021c24cdbea1c3c12c966073708e83db60c2","analyzedAt":"2026-08-12T22:14:19.293Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}