Match Numbers Between Brackets []

I am attempting to isolate the numbers that are in a description posted to a Webhook in n8n. The numbers are between square brackets and what I’m trying doesn’t work.

{{$json["body"]["project"]["name"].match(/\\[(.*?)\\]/)}}

String:

Ticket 1234 - Not So Clever Admin [8675309]

This should work:

{{ $json["body"]["project"]["name"].match(/\[(\d+)]/)[1] }}

Example workflow:

That did work, thank you @jan.

Glad to hear. Have fun!