You can use a FOR /F loop and with the options "TOKENS=2 DELIMS=/" you can get the value from the URL string passed in as the first argument at batch script execution after its (the URL value) second forward slash (/) but before the next forward slash (/) giving you the expected result exactly as you describe you need from that part of the URL.
You can SET the parsed URL string as a variable value and use that to pass as the first argument to the application executable file. I'll put a couple batch script examples below to help further clarify.
#1. Batch Script
@echo off
echo %~1
FOR /F "TOKENS=2 DELIMS=/" %%A IN ("%~1") DO (SET "var=%%~A")
echo %var%
pause
exit 0
#2. Batch Script
@ECHO OFF
FOR /F "TOKENS=2 DELIMS=/" %%A IN ("%~1") DO (CALL C:/someapp.exe "%%~A")
EXIT 0
#1. Correlated Output Results
C:\Users\User\Desktop> test.bat "testapp://close/"
testapp://close/
close
Press any key to continue . . .

Further Resources
- FOR /F
FOR /?
delims=xxx - specifies a delimiter set. This replaces the
default delimiter set of space and tab.
tokens=x,y,m-n - specifies which tokens from each line are to
be passed to the for body for each iteration.
This will cause additional variable names to
be allocated. The m-n form is a range,
specifying the mth through the nth tokens. If
the last character in the tokens= string is an
asterisk, then an additional variable is
allocated and receives the remaining text on
the line after the last token parsed.