The CreateParserInputV2 is the input for creating a parser. It includes various settings.

Table: CreateParserInputV2

ParameterTypeRequiredDefaultStabilityDescription
Some arguments may be required, as indicated in the Required column. For return datatypes, this indicates that you must specify which fields you want returned in the results.
Table last updated: Mar 28, 2025
allowOverwritingExistingParserboolean falseLong-TermAllows saving a parser with a name that is already in use, by overwriting the parser that previously had the name.
fieldsToTag[string]yes Long-TermFields that are used as tags.
fieldsToBeRemovedBeforeParsing[string]yes Long-TermA list of fields that will be removed from the event before it's parsed. These fields will not be included when calculating usage.
languageVersionLanguageVersionInputType {name: ”legacy“}Long-TermA specific language version. See LanguageVersionInputType.
namestringyes Long-TermThe name to use for the parser.
repositoryNameRepoOrViewNameyes Long-TermThe repository where the parser is located. RepoOrViewName is a scalar.
scriptstringyes Long-TermThe parser script that is executed for every incoming event.
testCases[ParserTestCaseInput]yes Long-TermTest cases that can be used to help verify that the parser works as expected. See ParserTestCaseInput.