{
“subflows”: [
{
“flow”: [
{
“id”: 125,
“module”: “regexp:Parser”,
“version”: 1,
“parameters”: {
“global”: false,
“pattern”: “(?:id=|folders/|/d/)([a-zA-Z0-9_-]+)”,
“multiline”: false,
“sensitive”: true,
“singleline”: false,
“continueWhenNoRes”: false
},
“mapper”: {
“text”: “{{109.text}}”
},
“metadata”: {
“designer”: {
“x”: 2700,
“y”: 0,
“name”: “Parse any Google Drive link”
},
“restore”: {},
“parameters”: [
{
“name”: “pattern”,
“type”: “text”,
“label”: “Pattern”,
“required”: true
},
{
“name”: “global”,
“type”: “boolean”,
“label”: “Global match”,
“required”: true
},
{
“name”: “sensitive”,
“type”: “boolean”,
“label”: “Case sensitive”,
“required”: true
},
{
“name”: “multiline”,
“type”: “boolean”,
“label”: “Multiline”,
“required”: true
},
{
“name”: “singleline”,
“type”: “boolean”,
“label”: “Singleline”,
“required”: true
},
{
“name”: “continueWhenNoRes”,
“type”: “boolean”,
“label”: “Continue the execution of the route even if the module finds no matches”,
“required”: true
}
],
“expect”: [
{
“name”: “text”,
“type”: “text”,
“label”: “Text”
}
],
“interface”: [
{
“name”: “$1”,
“type”: “text”,
“label”: “$1”
}
]
}
}
]
}
],
“metadata”: {
“version”: 1
}
}
Hey Rafael,
I assume this is not working? And what does the input look like?
You can use a Text Parser “Match Pattern” module with this pattern (regular expression):
(?<=(?:d|folders)\/|id=)(?<id>[^\/?&\s]+)
Proof https://regex101.com/r/pTNNUE/2
Important Info
Global match must be set to NO!
For more information, see the Text Parser page in the Make Help Center:
Match Pattern
The Match pattern module enables you to find and extract string elements matching a search pattern from a given text. The search pattern is a regular expression, which is a sequence of characters in which each character is either a metacharacter, having a special meaning, or a regular character that has a literal meaning.
- The complete list of metacharacters can be found on the MDN web docs website.
- For a tutorial on how to create regular expressions, we recommend the RegexOne website.
- For an easy, quick regex generator, try the Regular Expressions generator.
- For experimenting with regular expressions, we recommend the regular expressions 101 website. Just make sure to select the ECMAScript (JavaScript) flavour in the left panel.
Alternatively, you can possibly use a few built-in functions to save an operation:
Hope this helps! If you are still having trouble, please provide more details.
— @samliew

