Looks OK. I only have four suggestions:
Use printf rather than echo. See Why is printf better than echo?
Put the URL at the end of the command, not in the middle. And put it in a variable, e.g. $URL.
Use \ and newlines and indentation to make your code more readable. Long lines, especially those wider than your terminal/editing-window are a PITA. e.g.
URL='https://bin.tcc.li/artifactory/api/security/token'
result=$(curl -sSf -XPOST \
--header "X-JFrog-Art-Api: $ARTIFACTORY_API_KEY" \
-d "username=$ARTIFACTORY_SVC_ACCT" \
-d "scope=member-of-groups:*" \
"$URL" > /dev/null && echo "success")
If necessary use variables to shorten the lines. A few variable assignments aren't going to make any noticeable impact on performance (unless done thousands of times in a loop - so avoid doing that), but can make your code a lot easier to read.
e.g. the X-JFrog-Art-Api: $ARTIFACTORY_API_KEY header and the -XPOST URL can both be put into variables, as can the username= and scope= -d data options.
You don't need command substitution to get a $result variable. You're already testing the exit code from curl with && echo success - you can do that directly in the if statement.
#!/bin/bash
URL='https://bin.tcc.li/artifactory/api/security/token'
API_KEY="X-JFrog-Art-Api: $ARTIFACTORY_API_KEY"
username_data="username=$ARTIFACTORY_SVC_ACCT"
scope_data='scope=member-of-groups:*'
if curl -sSf -XPOST \
--header "$API_KEY" \
-d "$username_data" \
-d "$scope_data" \
"$URL" > /dev/null 2>&1; then
result='success'
printf "%s" "$result"
printf "%s\n" "Your general Artifactory access is successful"
else
printf "%s\n" "Connection to Artifactory failed"
fi
and you only need the result=success if you're going to use that variable later in the script. I can't see any benefit in printing it either.
Or you could capture the actual output from curl into $result (rather than just "success" or nothing) if you have a use for it, and still use curl's exit code for the if statement.