Does AppleScript's do shell script log in history?
If you run the following do shell script command in Script Editor:

do shell script "set"


Shown farther below is what's returned.

As one can see, there are no history related shell variables set and as such, to make a longer story short, there is no command history being saved.

If you want to read further, have a look at the HISTORY section in the bash manual page,

Also may be of interest, other command history Shell Variables e.g., HISTCONTROL, HISTFILE HISTFILESIZE, HISTIGNORE, HISTSIZE, HISTIGNORE, HISTSIZE and HISTTIMEFORMAT.



Also of note, when a Run Shell Script action in an Automator workflow is run, the same applies there as well, for the same reason as with the do shell script command in Script Editor, no history related shell variables are set.



Output of the set command from an AppleScript do shell script command:

Apple_PubSub_Socket_Render=/private/tmp/com.apple.launchd.HPRIi1Tsop/Render
BASH=/bin/sh
BASH_ARGC=()
BASH_ARGV=()
BASH_EXECUTION_STRING=set
BASH_LINENO=()
BASH_SOURCE=()
BASH_VERSINFO=([0]=\"3\" [1]=\"2\" [2]=\"57\" [3]=\"1\" [4]=\"release\" [5]=\"x86_64-apple-darwin17\")
BASH_VERSION='3.2.57(1)-release'
DIRSTACK=()
EUID=501
GROUPS=()
HOME=/Users/me
HOSTNAME=mes-Mac.local
HOSTTYPE=x86_64
IFS='   
'
LOGNAME=me
MACHTYPE=x86_64-apple-darwin17
OPTERR=1
OPTIND=1
OSTYPE=darwin17
PATH=/usr/bin:/bin:/usr/sbin:/sbin
POSIXLY_CORRECT=y
PPID=4330
PS4='+ '
PWD=/
SHELL=/bin/bash
SHELLOPTS=braceexpand:hashall:interactive-comments:posix
SHLVL=1
SSH_AUTH_SOCK=/private/tmp/com.apple.launchd.WQb3vmbYE7/Listeners
TERM=dumb
TMPDIR=/var/folders/w0/lht0h70x06b8hdb5lx474pkc0000gn/T/
UID=501
USER=me
XPC_FLAGS=0x0
XPC_SERVICE_NAME=0
_=sh
__CF_USER_TEXT_ENCODING=0x1F5:0x0:0x0