Read Self Register Request using 11g API

Gurus,
I am trying to read Self Register Request using API but I am getting beneficiaries and requester data as null.
Can you please provide some code snippet to read beneficiary data from a Self Register Request.

Gurus,
I am trying to read Self Register Request using API but I am getting beneficiaries and requester data as null.
Can you please provide some code snippet to read beneficiary data from a Self Register Request.

Similar Messages

  • Creating self registration request using OIM API

    Hi guys,
    When we try to create a self regisrtation request using OIM API , we ge the following exception:
    We get this error when we set the following in Design console.
    Does user have to provide challenge information during registration = FALSE
    and passed an blank object in place of challenge question parameter in createSelfRegistrationRequest method in tcUtilityBaseClass.
    19:22:17,218 ERROR [REQUESTS] Error: Failed to save REQ_CONSOLIDATED_DATA_VALUE
    data for Create Entity.
    java.lang.NullPointerException
    at org.apache.xml.serializer.TreeWalker.dispatachChars(TreeWalker.java:2
    44)
    at org.apache.xml.serializer.TreeWalker.startNode(TreeWalker.java:414)
    at org.apache.xml.serializer.TreeWalker.traverse(TreeWalker.java:143)
    at org.apache.xalan.transformer.TransformerIdentityImpl.transform(Transf
    ormerIdentityImpl.java:389)
    at com.thortech.xl.dataobj.util.RequestDataConsolidator.convertNodeToXML
    (Unknown Source)
    at com.thortech.xl.dataobj.util.RequestDataConsolidator.addUser(Unknown
    Source)
    at com.thortech.xl.dataobj.tcDataBase.createRequestForCreateEntity(Unkno
    wn Source)
    at com.thortech.xl.dataobj.tcDataBase.createRegistrationRequest(Unknown
    Source)
    at com.thortech.xl.dataobj.tcDataBase.createRegistrationRequest(Unknown
    Source)
    at com.thortech.xl.ejb.beansimpl.tcUnauthenticatedOperationsBean.createR
    egistrationRequest(Unknown Source)
    at com.thortech.xl.ejb.beans.tcUnauthenticatedOperationsSession.createRe
    gistrationRequest(Unknown Source)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.jboss.invocation.Invocation.performCall(Invocation.java:359)
    at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(S
    tatelessSessionContainer.java:237)
    at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invo
    ke(CachedConnectionInterceptor.java:158)
    at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(Stat
    elessSessionInstanceInterceptor.java:169)
    at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidation
    Interceptor.java:63)
    at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInte
    rceptor.java:121)
    How do we create a self registration request , using OIM API , with and without challenge questions?

    Well try this piece of code. This might be similar to yours but it worked perfectly for me. For you the error might be the attribute names which you are passing, it should be the one dfined in the FormMetaData xml as below.
         import Thor.API.tcUtilityFactory;
         // define you class below
         ConfigurationClient.ComplexSetting config = ConfigurationClient.getComplexSettingByPath("Discovery.CoreServer");
         final Hashtable env = config.getAllSettings();
         Hashtable quesAns = new Hashtable();
         HashMap user = new HashMap();
         user.put("Users.User ID", "SelfTesting");
         user.put("Users.First Name", "SelfTesting");
         user.put("Users.Last Name", "SelfTesting");
         user.put("Users.Email", "[email protected]");
         user.put("Users.Password", "SelfTesting");
         user.put("ConfirmPassword", "SelfTesting");
         tcUtilityFactory.createRegistrationRequest(env, user, quesAns);
    And for the query of challenge QnA, these are the following combinations possible:
    1) Property Does user have to provide challenge information during registration set to TRUE
    - During self-registration from web console, it will show you Challenge Questions section on the right. If you do not select any questions, it will thow you an error there itself.
    - Doing it from API will create no difference(even if you pass a blank HashTable). The request will be created successfully and on completion when the user tries to login, it will ask for Security QnA.
    2) Property Does user have to provide challenge information during registration set to FALSE
    - During self-registration from web console, it doesn't show you Challenge Questions section on the right. The request will be created successfully and on completion when the user tries to login, it will ask for Security QnA.
    - Doing it from API, you will have to pass a blank HashTable as in above code. The request will be created successfully and on completion when the user tries to login, it will ask for Security QnA.
    Hope it works.
    Thanks
    Sunny

  • Raising Request using OIM ApI's in oim 11g R2

    Hi all
    I trying to raise a request using OIM API in R2. I have written a sample code and it is throwing me the below error....
    Exception in thread "main" java.lang.NullPointerException
    *     at oracle.iam.ui.custom.updateuser.<init>(updateuser.java:76)*
    *     at oracle.iam.ui.custom.updateuser.main(updateuser.java:118)*
    Please take a look at my code....
    RequestEntityAttribute rea = null;
    rea.setName("Modify User Profile");//This is the place where i am getting the error...
    System.out.println("I am Here3");
    rea.setAction(RequestEntityAttribute.ACTION.Modify);
    List<RequestEntityAttribute> lrea = new ArrayList<RequestEntityAttribute>();
    lrea.add(rea);
    RequestEntity re = null;
    re.setEntityData(lrea);
    List<RequestEntity> reqentity = new ArrayList<RequestEntity>();
    reqentity.add(re);
    RequestData requestData = null;
    requestData.setJustification("I need this Role");
    requestData.setTargetEntities(reqentity);
    String str = null;
    try {
    str = _service.submitRequest(requestData);
    } catch (InvalidRequestException e) {
    } catch (InvalidRequestDataException e) {
    } catch (RequestServiceException e) {
    } catch (BulkBeneficiariesAddException e) {
    } catch (BulkEntitiesAddException e) {
    Thanks in Advance

    look at below link
    Creating a Request via OIM 11g API
    http://www.pathmaker-group.com/querying-oracle-iam-requests/

  • Approving Self-Registration request using API

    Hi all
    As an end user I have created a self registration request using using the method, createRegistrationRequest from utility factory.
    Now as an approver , i wanted to approve the request. I have updated the Organization name using updateRegistrationUserDetails method in tcRequestOperationsIntf by passing
    hashMap.put("Organizations.Organization Name",
    "Requests");
    reqOper.updateRegistrationUserDetails(reqAppSet
    .getLongValue("Requests.Request ID"),hashMap);
    This is working fine. However when I use the following procedure to approve this request ,
    reqOper.setRequestResponse(reqAppSet
    .getLongValue("Requests.Key"), getUsrKey("XELSYSADM"), "Approve");
    it throws the following exception
    Thor.API.Exceptions.tcAwaitingApprovalDataCompletionException
    at com.thortech.xl.ejb.beansimpl.tcRequestOperationsBean.setRequestResponse(Unknown Source)
    at com.thortech.xl.ejb.beans.tcRequestOperationsSession.setRequestResponse(Unknown Source)
    What else needs to be done in this approving aspect for the task to be approved?
    Thank you
    Regards
    shashidhar

    Hi all
    I found the solution,
    along with this ,
    hashMap.put("Organizations.Organization Name",
    "Requests");
    you need to update ,
    Employee -Type and User Type
    Thank you
    shashidhar

  • Change self-register request template

    Hi there!
    Is it possible to change the request template for self-register to a newly created?
    If it so, how can i archive that?
    I did some searching, but i couldn't find anything on the web.

    You want initiate approval through Self Registration itself but when you are doing Self Registration then User is still not created in OIM so how OIM can raise request for that user.
    You can do one more thing, Create a group & attach an Access Policy with Approval with that group. As user comes into OIM, approval process will get initiated.
    Q: How you will identitfy that which user has come into OIM through Self Registration.
    A: Add one UDF in Self Registration and give some constant value through Self Registration and add Membership rule for group based on value of this UDF.

  • Read an Excel file using POIFSFileSystem API

    hello,
    I'm working on J2EE web assignment. Following is my requirement
    1) User select local excel file and hit submit
    2) API takes that file read and create a new Excel file.
    I am wondering if I can somehow get inputsteam on form post and then pass it to POI api
    POI api syntax
    POIFSFileSystem fs = new POIFSFileSystem(java.io.InputStream);
    thanks,
    Amit

    there are plenty of tutorials and docs online
    this site is for technical help, general questions should be submitted to Google

  • I need to get the current assignee for a given request using SOA's java api

    I'm developing a spring app that interfaces with Oracle SOA suite and executes the actions such as approving requests using the api. I need to get the current assignee for each SOA Task this is dispalyed in the OIM console so it is getting it from somewhere. I tried getApprovers in the ITaskService api but this returns an empty list

    I have checked it once again and there indeed are links for ALUI components for Solaris on SPARC at edelivery.oracle.com. (Officially ALUI supports Solaris on SPARC only)
    If you have looked at Solaris x86, then you must not have found them. Please make sure that you are selecting the righ platform. Also, make sure that you click on the Aqualogic media pack so as to get the lists of the components included in it. (Point to Note: You need to go to the next level)
    For whichever component you are not able to find, try looking for it in the Metalink (My Oracle Support) if you have a support contract.

  • Request Approval using OIM API

    Hi all
    Which API I need to use to approve a resouce request using OIM API?
    I have tried with the following:
    tcReqOp.setRequestResponse(85, 1 , "java.lang.String psResponse");
    i do not know what to pass in place of java.lang.String psResponse.
    I aslo tried passing "C","Completed"
    can anyone correct what I am doing?
    Thank u
    sas

    I assume you want to run a scheduled task for this. Try this approach. Run this query to retrieve specific approval tasks that are in a pending state:
    select oti.sch_key, mil.mil_name, to_char(oti.oti_update, 'dd-mon-yyyy hh24:mi:ss')
    from oti, mil, obj, pkg, orc, sch
    where oti.mil_key=mil.mil_key
    and oti.pkg_key=pkg.pkg_key
    and pkg.obj_key=obj.obj_key
    and oti.orc_key=orc.orc_key
    and oti.sch_key=sch.sch_key
    and oti.sch_status='P'
    and obj.obj_name='Test Object'
    and pkg.pkg_type='Approval'
    You can modify the obj.obj_name or remove, or do any changes you want. When you grab the time of the oti.oti_update, compare it against the sysdate to determine the time difference. If the update did not occur within that time, use this code:
    provIntf = (tcProvisioningOperationsIntf)getUtilityOps("Thor.API.Operations.tcProvisioningOperationsIntf");
    Hashtable taskHash = new Hashtable();
    taskHash.put("Process Instance.Task Details.Data", "<Insert Response Value Here>");
    provIntf.updateTask(key, taskHash) ; //---> Key is the same as the oti.sch_key field
    I have not tried this, but give it a shot.
    -Kevin

  • Error on accessing the OIM Self Register page.

    Hi,
    I had modified the 'Self Register' Request template on the Admin Console UI to include a new custom attribute.
    Since then, I have removed the custom attribute from the User Configuration and uploaded a new SelfCreateUserDataset.xml.
    On accessing the self register page, it throws the an error with the following message: -
    "Invalid restriction specified for the attribute Role in template Self-Register User. Corresponding Attribute or Attribute Reference not found in the Request Data Set."
    Kindly let me know how to restore the template in UI to the factory setting.
    Thank you,
    Bhaskar

    -

  • Backup without using SMS API!

    Hi,
    I am using regular FS APIs opendir(), readdir(), stat() to collect items to backup files from NSS volumes and then during backup I am using regular FS APIs open(), read(), etc to read data streams and using z APIs, zGetInfo(), zModiInfo(), zAddTrustee(), zGetTrustee(), etc to read/write Trustee and extended attributes.
    My question is, how different will it be as opposed to using SMS APIs for the same above stated operations with respect to
    1) performance
    2) being able to backup/restore all possible trustee and extended attributes information
    3) future support
    Thanks,
    Manoj

    In the absence of SMS, the zAPIs will be the way to do things for NSS, and since you are removing an layer of abstraction, should be faster. Also, the extended attributes are exposed via zAPI. It also means you can handle compressed streams, creepy apple stuff that can be exposed via AFP. While NSSifying things, you should also look at the modified file list capabilities. That can eliminate the enumeration and reconciliation phase most incremental backup processes require. For example, if you had to dredge through the metadata of a 8 million file file system just to find 2000 modified files.... the MFL is very useful. In fact, if you are looking to do "continuous" backup - which I would be willing to pay for :-) so do a good job, please - using feature like this allow for rapid acquisition of the deltas.
    -- Bob

  • How to use tcRequestOperationsIntf API to create a self-request?

    According to documentation, I can use tcRequestOperationsIntf API methods to create and manage requests.
    How can I use these methods to initiate a self-request (for provisioning user a new resource)?
    Because when I create a usual request, it's equivalent to direct provisioning the resource (from the user's resource profile) then all approval processes are bypassed :(

    While tcUserOperationsIntf.provisionResource would provision the resource to the user bypassing the approval, tcRequestOperationsIntf can be used to raise a request to provision a user with a resource along with approval, if approval is defined for that resource in the approval process.
    Here is a sample code for raising a request to provision user (lUserKey) with resource object (lObjectKey)
    ///Created the request object for provisioning the RO
    requestObj = (tcRequestOperationsIntf) utilFactory.getUtility("Thor.API.Operations.tcRequestOperationsIntf");
    HashMap reqMap = new HashMap();
    reqMap.put("Requests.Target Type", "U");
    reqMap.put("Requests.Object Request Type", "Add");
    reqMap.put("Requests.Type", "U");
    lRequestKey = requestObj.createRequest(reqMap);
    //Adding user to be provisioned for
    requestObj.addRequestUser(lRequestKey, lUserKey);
    //Adding object to be provisioned
    requestObj.addRequestObject(lRequestKey, lObjectKey);
    //create the request
    requestObj.completeRequestCreation(lRequestKey);
    Hope it helps,
    Rgds, Ajay

  • Approving OIM/SOA requests using OIM 11g APIs

    I'm creating a SOA request using createRequest method in RequestService OIM API. I would like to approve/reject the work items using the API as well but I don't see any methods to approve/reject the tasks. Is this something I would have to use SOA's webservices to do it?
    Thanks

    You need to use BPEL worklist API for the same.
    http://technology.amis.nl/blog/1496/invoking-bpel-worklist-api-from-remote-server-with-java
    http://docs.oracle.com/cd/E12839_01/integration.1111/e10224/bp_worklistcust.htm
    -Bikash

  • Auto approval for self registration request in OIM 11G R2

    Hi all,
    We have a requirement where we want end users to be able to self-register without needing any sort of approval. We are using OIM 11G R2 with the latest patchset.
    The way to do it in 11G R1 is explained in the following document:
    [http://docs.oracle.com/cd/E21764_01/doc.1111/e14316/unauth_selfservice.htm#BABFEIBF]
    But now that R2 does not have any request templates, we are not sure how to do this. Any help will be greatly appreciated. Thanks for your time.
    -sandeepc

    refer this.
    Configuring Auto-Approval for Self-Registration - Fails due to Organisation

  • Creating a Request via OIM 11g API

    I'm trying to create a request in OIM using the API. I found this post ( OIM 11g - Setting Process Form Data through Request API ) which has the code to do it but I'm getting an error:
    Here is what I have
    OIMClient client = getOIMClient(url, username, password);
          long resKey = 0L;
          String str = null;
          String resourceKey = null;
          Map<String, String> searchMap = new HashMap<String, String>();
          tcResultSet resultSet = null;
          RequestData requestData = null;
          Beneficiary beneficiary = null;
          RequestBeneficiaryEntity entity = null;
          List<Beneficiary> beneficiaryList = new ArrayList<Beneficiary>();
          List<RequestBeneficiaryEntity> entityList = null;
          List<RequestBeneficiaryEntityAttribute> entityAttrList = null;
          String RESOURCE = "TESTRESOURCE_GTC";
          tcITResourceInstanceOperationsIntf operations = client.getService(tcITResourceInstanceOperationsIntf.class);
          Map<String, String> conditions = new HashMap<String, String>();
          conditions.put("IT Resources.Name", "TESTRESOURCE_GTC");
          resultSet = operations.findITResourceInstances(conditions);           
          resKey = resultSet.getLongValue("IT Resource.Key");
          resourceKey = Long.toString(resKey);
          RequestBeneficiaryEntityAttribute parantAttr = new RequestBeneficiaryEntityAttribute();
          parantAttr.setType(TYPE.String);
          parantAttr.setName("Title");
          parantAttr.setValue("Mr.");
          entityAttrList = new ArrayList<RequestBeneficiaryEntityAttribute>();
          entityAttrList.add(parantAttr);
          entity = new RequestBeneficiaryEntity();
          entity.setEntityKey(resourceKey);
          entity.setEntityType(RequestConstants.RESOURCE);
          entity.setEntitySubType(RESOURCE);
          entity.setEntityData(entityAttrList);
          entityList = new ArrayList<RequestBeneficiaryEntity>();
          entityList.add(entity);
          System.out.println("*********** USR KEY" + usrKey);
          beneficiary = new Beneficiary();
          beneficiary.setBeneficiaryType(Beneficiary.USER_BENEFICIARY);
          beneficiary.setBeneficiaryKey(usrKey);
          beneficiary.setTargetEntities(entityList);
          beneficiaryList.add(beneficiary);
          requestData = new RequestData();
          requestData.setRequestTemplateName("Self-Request Resource");
          requestData.setJustification("Test");
          requestData.setBeneficiaries(beneficiaryList);
          UnauthenticatedRequestService reqsrvc = client.getService(UnauthenticatedRequestService.class);
          str = reqsrvc.submitRequest(requestData);
          System.out.println("Value from submitRequest : '" + (str != null ? str : null) + "'");I'm getting
    <Feb 14, 2012 4:53:24 PM EST> <Error> <oracle.iam.request.impl> <IAM-2050128> <Invalid beneficiary key was specified for Self-Request. >
    oracle.iam.request.exception.InvalidRequestDataException: IAM-2050128:Invalid beneficiary key was specified for Self-Request.
    I can see that USER KEY is getting populated.
    Edited by: DJ on Feb 14, 2012 4:59 PM
    Edited by: DJ on Feb 14, 2012 5:00 PM

    While creating a request to provision iPlanet User one of the errors I was getting:
    oracle.iam.request.exception.RequestServiceException: IAM-2050061:Type mismatch for the attribute Server. The type passed is String, but the corresponding type in the data set is Long.:Server:String:Long
    So I replaced the value of the attribute Server to the IT Resource.Key which is 5. After making the changes, it goes through approvals with no problems, but when I approve all the work items, it errors out with an error:
    Error occurred while provisioning resource with key 45 to user 5
    User Key is 45 and Resource Key is 5. I'm not sure why it swapped it.
    Here is the code I'm using:
    public static void createRequest(String userLogin, String templateName, String resourceName, HashMap<String, Object> attrs, OIMClient client) {
        try {
          String usrKey = searchUserByLogin(userLogin, client).get(0).getId();
          long resKey = 0L;
          String str = null;
          String resourceKey = null;
          Map<String, String> searchMap = new HashMap<String, String>();
          tcResultSet resultSet = null;
          RequestData requestData = null;
          Beneficiary beneficiary = null;
          RequestBeneficiaryEntity entity = null;
          List<Beneficiary> beneficiaryList = new ArrayList<Beneficiary>();
          List<RequestBeneficiaryEntity> entityList = null;
          List<RequestBeneficiaryEntityAttribute> entityAttrList = new ArrayList<RequestBeneficiaryEntityAttribute>();
          tcITResourceInstanceOperationsIntf operations = client == null ? Platform.getService(tcITResourceInstanceOperationsIntf.class) : client.getService(tcITResourceInstanceOperationsIntf.class);
          Map<String, String> conditions = new HashMap<String, String>();
          conditions.put("IT Resources.Name", resourceName);
          resultSet = operations.findITResourceInstances(conditions);
          resKey = resultSet.getLongValue("IT Resource.Key");
          resourceKey = Long.toString(resKey);
          for (String attr : attrs.keySet()) {
            RequestBeneficiaryEntityAttribute parantAttr = new RequestBeneficiaryEntityAttribute();
            if (attrs.get(attr) instanceof String) {
              parantAttr.setType(TYPE.String);
              parantAttr.setName(attr);
              parantAttr.setValue(String.valueOf(attrs.get(attr)));
              entityAttrList.add(parantAttr);
            } else if (attrs.get(attr) instanceof Long) {
              parantAttr.setType(TYPE.Long);
              parantAttr.setName(attr);
              parantAttr.setValue(String.valueOf(attrs.get(attr)));
              entityAttrList.add(parantAttr);
            } else {
              // do nothing
          entity = new RequestBeneficiaryEntity();
          entity.setEntityKey(resourceKey);
          entity.setEntityType(RequestConstants.RESOURCE);
          entity.setEntitySubType(resourceName);
          entity.setEntityData(entityAttrList);
          entityList = new ArrayList<RequestBeneficiaryEntity>();
          entityList.add(entity);
          beneficiary = new Beneficiary();
          beneficiary.setBeneficiaryType(Beneficiary.USER_BENEFICIARY);
          beneficiary.setBeneficiaryKey(usrKey);
          beneficiary.setTargetEntities(entityList);
          beneficiaryList.add(beneficiary);
          requestData = new RequestData();
          requestData.setRequestTemplateName(templateName);
          requestData.setJustification("Test");
          requestData.setBeneficiaries(beneficiaryList);
          System.out.println("Resource Keys " + resKey + " " + resourceKey);
          System.out.println("User Key " + usrKey);
          RequestService reqsrvc = client == null ? Platform.getService(RequestService.class) : client.getService(RequestService.class);
          str = reqsrvc.submitRequest(requestData);
          System.out.println("Value from submitRequest : '" + (str != null ? str : null) + "'");
        } catch (Throwable t) {
          t.printStackTrace();
      }Edited by: DJ on Feb 16, 2012 5:01 PM

  • How to find bpel instance in 11g based on the index values using Java APIs

    Hi ,
    In SOA10G we had option to find the instances based on the index value using Java APIs like below.
    WhereCondition criteria= new WhereCondition(SQLDefs.CX_index_1 + " = ?");
    criteria.setString(1, "indexValue");
    Locator mLoc = getLocator();
    IInstanceHandle[] foundInstances = mLoc.listInstancesByIndex(criteria);
    Please tell me how to achieve the same functionality in SOA 11G using Java APIs
    Regards,
    Saba

    I have multiple bpel in my composite. I checked in ci_indexes table and it shows the instance number of the bpel process. But the em console is showing only the composite instance number. when I opened composite instance, I could see all the bpel process with instance number in the audit trail. How can I find the the actual composite instance number that I should search for in the em console ???

Maybe you are looking for

  • Setting focus to new instance of a field...need help.

    Hi there, I have a flowed form which consists of multiple subforms. I have one subform which is basically one textfield that is set to a min of 1 and a max of 5. These are to correspond to fields in our system of record that have 5 fields for company

  • Java.policy codebase ignored

    I've recently been trying to allow an applet on a local webpage to write to a file in the same folder. I've been using the following .java.policy file: grant codeBase "file:${user.home}/My Documents/folder/*" {   permission java.io.FilePermission "${

  • Adobe Air Packager for RoboHelp

    Hello! I have been experimenting with the RoboHelp Packager for Adobe Air. I really like the many extra features using Adobe Air allows for Help Files and of course, I also like that you can finally do a Help File that looks and feels more up-to-date

  • After updating to Maverick on my MacPro it no longer sees both CD drives Help

    After updating to Maverick on my MacPro it no longer sees both CD drives Can anyone help? When I hit the eject key only the bottom drive ejects........ Thanks [email protected]

  • Power Failier causing G4 (Tiger) not to start up properly

    I think this has been asked before but cant find an answer... After an unexpected power cut I try and restart my G5 running 10.4 (Tiger) but it fails to start properly, showing only the spotlight icon in the top right of the screen. All the other mac