Recording File name with additional attributes via PHPAgi

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Recording File name with additional attributes via PHPAgi

Postby Emaster » Thu Oct 25, 2018 9:20 am

Hello Everyone,
We are using Vici 8 On VM machine,
I am currently experimenting with my own AGI scripts with some success, But I currently i have a gigantic wall in front of my goal.
I Would like to know if is possible to change a name of a Recording File which is recorded via ViciDial and add or completely change the name of the file based on Text and number attributes which are generated via PHPAgi Script.

Kind Regards
Emaster
 
Posts: 1
Joined: Thu Oct 11, 2018 8:50 am

Re: Recording File name with additional attributes via PHPAg

Postby williamconley » Mon Jan 14, 2019 6:59 pm

1) Welcome to the Party! 8-)

2) As you are obviously new here, I have some suggestions to help us all help you:

When you post, please post your entire configuration including (but not limited to) your installation method (7.X.X?) and vicidial version with build (VERSION: 2.X-XXXx ... BUILD: #####-####).

This IS a requirement for posting along with reading the stickies (at the top of each forum) and the manager's manual (available on EFLO.net, both free and paid versions)

You should also post: Asterisk version, telephony hardware (model number is helpful here), cluster information if you have one, and whether any other software is installed in the box. If your installation method is "manual/from scratch" you must post your operating system with version (and the .iso version from which you installed your original operating system) plus a link to the installation instructions you used. If your installation is "Hosted" list the site name of the host.

If this is a "Cloud" or "Virtual" server, please note the technology involved along with the version of that techology (ie: VMware Server Version 2.0.2). If it is not, merely stating the Motherboard model # and CPU would be helpful.

Similar to This:

Vicibox X.X from .iso | Vicidial X.X.X-XXX Build XXXXXX-XXXX | Asterisk X.X.X | Single Server | No Digium/Sangoma Hardware | No Extra Software After Installation | Intel DG35EC | Core2Quad Q6600

3) This is in no way a "general discussion", it's a support request. Moving to the Support Board accordingly.

4) First please explain why you don't just use the "Campaign Rec Filename" on the Modify Campaign screen. (Not being a smartass here, or picking on you: This information will be useful for all those who try to assist you in this endeavor PLUS I'd hate to not ask and have you find out next month you could have just used this field to make your changes! lol).

5) AFTER the recording is completed, mixed and compressed, you could write a script that modifies the filename and also updates the filename in the Vicidial recordings table. In theory that would keep Vicidial linked to the file with the new name. Don't forget that there is also an FTP script designed to move the final recordings to an archive server (thus removing them from the HD of the dialers to "bulk long-term storage"). That FTP process modifies the URL at which the files are retrieved as well, so test the FTP transfer after modifying the filenames as a confirmation that nothing is broken. To verify: make sure the Links in the User and Lead records still acquire your newly named file even after FTP transfer.

6) You COULD even modify the FTP transfer script to your nefarious purpose since it makes similar changes. 8-)

Happy Hunting!
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # +44(203) 769-2294
williamconley
 
Posts: 20258
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Recording File name with additional attributes via PHPAg

Postby mflorell » Tue Jan 15, 2019 7:05 am

There already are features for modifying recording filenames after a recording is completed:

Campaign Rec Filename -
This field allows you to customize the name of the recording when Campaign recording is ONDEMAND or ALLCALLS. The allowed variables are CAMPAIGN INGROUP CUSTPHONE FULLDATE TINYDATE EPOCH AGENT VENDORLEADCODE LEADID CALLID RECID. If your dialers have --POST recording processing enabled, you can also use POSTVLC POSTSP POSTARRD3 POSTSTATUS. These POST options will alter the recording file name after the call has been finished and will replace the post variable with the value from the default fields. The default is FULLDATE_AGENT and would look like this 20051020-103108_6666. Another example is CAMPAIGN_TINYDATE_CUSTPHONE which would look like this TESTCAMP_51020103108_3125551212. The resulting filename must be less than 90 characters in length.


# /usr/share/astguiclient/AST_CRON_audio_1_move_VDonly.pl --help
allowed run time options:
[--help] = this screen
[--quiet] = suppress output, if possible
[--debug] = debug
[--debugX] = super debug
[--test] = test
[--HTTPS] = use https instead of http in local location
[--POST] = post call variable filename replacement, MUST define STATUS and CAMP below
[--STATUS-POST=X] = only run post call variable filename replacement on specific status calls
If multiple statuses, use --- delimiting, i.e.: SALE---PRESALE
For status wildcards, use * flag, i.e.: S* to match SALE and SQUAL
For all statuses, use ----ALL----

[--CAMP-POST=X] = only run post call variable filename replacement on specific campaigns or ingroups
If multiple campaigns or ingroups, use --- delimiting, i.e.: TESTCAMP---TEST_IN2
For all calls, use ----ALL----
[--CLEAR-POST-NO-MATCH] = clear POST filename variables if no match is found
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida


Return to Support

Who is online

Users browsing this forum: No registered users and 105 guests