For the archives, in my CLLE program I did cd '/qopensys/pkgs/bin', then
added an envvar to fix an error per this page:

curl: (6) getaddrinfo() thread failed to start

https://bitbucket.org/ibmi/opensource/issues/92/curllib-7653
QIBM_MULTI_THREADED=Y

I'm able to get this to run in batch and leave the returned token to the
IFS. It's a cake walk from here :-)

CLP

PGM
CD DIR('/qOpenSys/pkgs/bin/')
ADDENVVAR ENVVAR(QIBM_MULTI_THREADED) VALUE(Y)
monmsg CPFA980

STRQSH CMD('curl --request POST --url +
https://xxxxx.com/token +
--header "accept: application/json" +
--header "authorization: Basic +
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx+
--data "{\"xxxxx_xxxx\": +
\"client_credentials\"}" -k > +
/tmp/token.txt')

endpgm

On Thu, Sep 10, 2020 at 6:46 PM Art Tostaine, Jr. <atostaine@xxxxxxxxx>
wrote:

My project needs to run in batch twice a day to get a login token for
another app.

On Thu, Sep 10, 2020 at 6:03 PM John Yeung <gallium.arsenide@xxxxxxxxx>
wrote:

On Thu, Sep 10, 2020 at 5:40 PM Mark Waterbury
<mark.s.waterbury@xxxxxxxxxxxxx> wrote:

Qshell is not PASE. Qshell is NOT "PASE." QSHELL IS NOT PASE!

Try using CALL QP2TERM ... if you want to do PASE stuff from a 5250 ...

While Qshell isn't PASE, the QSH command *is* still capable of
launching PASE commands. In fact, I always use QSH to launch PASE
commands, if it's within a CLP.

However, it is true that if you are working *interactively*, there is
pretty much no substitute for logging in via SSH and having a proper
TTY terminal.

I never use the QP2* commands at all. Ever.

John Y.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com



--
Art Tostaine




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.