Accepts
Contacts, Files, Images, Media, PDFs and Rich Text
TEXT
Made by thura10
If you have favourite devices, you can add it to the dictionary below so you don't have to enter it. It will be displayed in a list.
Name as the Key, IP address as the value

Text
DICTIONARY

Dictionary
TEXT
Enter the same secret key here and in airwave PC settings so you can send files without having to accept the prompt.
If you have changed the port number on PC, you should also change it below.
Time is the amount of time it will scan for your PC, if it takes too long, decrease it.
If it doesn't detect your PC, increase it.
Change in increments of 100 (100,200,etc)
If you don't want it to scan at all, put it as 1

Text
DICTIONARY

Dictionary
VARIABLES
Set variable
version
to
Shortcut Version
SCRIPTING
Get
Wi-Fi
network's
Network Name

Network Details
SCRIPTING
If
Network Details
does not have any value
SCRIPTING
Show alert
Informational Message
SCRIPTING
Exit shortcut with
Result
SCRIPTING
Otherwise
SCRIPTING
End If

If Result
SCRIPTING
Get
Value
for
Time (Don’t change)
in
Dictionary

Dictionary Value
SCRIPTING
Get
Value
for
Port
in
Dictionary

Dictionary Value
VARIABLES
Set variable
port
to
Dictionary Value
SCRIPTING
Get current IP address
Options Under Construction

Current IP Address
MISSING
Under Construction
SCRIPTING
Get dictionary from
Output

Dictionary
SCRIPTING
Choose from
Dictionary
Prompt
Choose your computer

Chosen Item
TEXT
Split
Chosen Item
by
Custom
-

Split Text
SCRIPTING
Get name of
Chosen Item

Name
SCRIPTING
If
Name
is
Custom
SCRIPTING
Ask
Please enter the code shown on your computer.
Default Answer
[{'class': 'magic', 'value': 'Chosen Item', 'glyph': '', 'UUID': 'E09A55EA-AEEA-48DC-8BC7-AD19D07B98CC'}]

Provided Input
TEXT
http://
Provided Input
:
port

Text
VARIABLES
Set variable
url
to
Text
SCRIPTING
Otherwise
SCRIPTING
Get
First Item
from
Split Text

Item from List
TEXT
http://
Item from List
:
port

Text
VARIABLES
Set variable
url
to
Text
SCRIPTING
End If

If Result
SCRIPTING
Count
Items
in
Split Text

Count
SCRIPTING
If
Count
is
1
SCRIPTING
Choose from Menu

Menu Result
SCRIPTING
Send to PC

Menu Result
TEXT
Send to PC

Text
VARIABLES
Set variable
mode
to
Text
SCRIPTING
Receive from PC

Menu Result
TEXT
Receive from PC

Text
VARIABLES
Set variable
mode
to
Text
SCRIPTING
End Menu

Menu Result
SCRIPTING
Otherwise
SCRIPTING
Get
Item At Index
2
from
Split Text

Item from List
VARIABLES
Set variable
mode
to
Item from List
SCRIPTING
End If

If Result
SCRIPTING
Get the
Device Name

Device Name
SCRIPTING
Get the
Device Model

Device Name
TEXT
Device Model
's
Device Name

Text
VARIABLES
Set variable
hostname
to
Text
SCRIPTING
If
mode
is
Send to PC
SCRIPTING
If
Shortcut Input
does not have any value
DOCUMENTS

File
VARIABLES
Set variable
files
to
File
SCRIPTING
Otherwise
VARIABLES
Set variable
files
to
Shortcut Input
SCRIPTING
End If

If Result
SCRIPTING
Count
Items
in
files

Count
VARIABLES
Set variable
key
to
Secret Key
SCRIPTING
Repeat with each item in
files

Repeat Results
DOCUMENTS
Get
Name
from
Repeat Item

Name
URL
url
/uploadfile

URL
NETWORK
Get contents of
URL
Options Under Construction

Contents of URL
DOCUMENTS
Get text from
Contents of URL

Text
SCRIPTING
If
Text
contains
cancel
SCRIPTING
Show alert
Informational Message
SCRIPTING
Exit shortcut with
Result
SCRIPTING
Otherwise
VARIABLES
Set variable
key
to
Text
SCRIPTING
End If

If Result
SCRIPTING
End Repeat

Repeat Results
SCRIPTING
Otherwise
SCRIPTING
If
mode
is
Receive from PC
LIST

List
URL
url
/filedata

URL
NETWORK
Get contents of
URL
Options Under Construction

Contents of URL
SCRIPTING
Repeat with each item in
Contents of URL

Repeat Results
NETWORK
Get contents of
Repeat Item
/
url
Options Under Construction

Contents of URL
DOCUMENTS
Get
File Extension
from
Contents of URL

File Extension
TEXT
Change
File Extension
to
lowercase

Updated Text
SCRIPTING
If
List
contains
Updated Text
PHOTOS
Save
Contents of URL
to
Recents

Saved Photo Media
MISSING
Open bplist00X$versionY$archiverT$topX$objects_NSKeyedArchiverTrootU$null_$242C0D4D-11C8-491C-AED2-FC928E6760EE$)27ILQSV\\
SCRIPTING
Otherwise
DOCUMENTS
Save
Contents of URL
Destination Path
/Shortcuts/TextOverwrite If File Exists

Saved File
SCRIPTING
End If

If Result
SCRIPTING
End Repeat

Repeat Results
DOCUMENTS
SCRIPTING
Otherwise
SCRIPTING
Show alert
Informational Message
SCRIPTING
Exit shortcut with
Result
SCRIPTING
End If

If Result
SCRIPTING
End If

If Result