CRM get stage Required Fields - dynamics-crm-2013

In Plug or workflow
How to get stage IDs or Names dynamically from entity
How to get current stage Required fields Names dynamically not hard coded Using c# or js or any other method
if any idea, Share please!

You can get an entity's metadata from CRM by issueing a RetrieveEntityRequest. In the response you get an EntityMetadata object having an Attributes collection providing all attribute details you need.
The CRM SDK contains clear example code on this topic. More information about working with attribute metadata can be found on MSDN.

I guess you are talking about the client functions to query the Business Process Flow attributes?
In CRM 2015 there is now clientside functionality implemented to the retrieve process, stage and step information.
With Xrm.Page.data.process.getActiveProcess() you can get the current workflow process and retrieve a Process object.
You can use the following methods to retrieve further and deeper information about the process:
Process:
string: .getId();
string: .getName();
stage[]:.getStages();
bool:.isRendered();
Stage :
string:.getId();
string: .getName();
int: .getCategory().getValue();| stage category Optionset
string: .getStatus(); | „active“ , „inctactive“
step[]:.getSteps();
bool:.isRendered();
Step (the attributes):
string: .getAttribute(); | logical attribute name
string: .getName();
stage[]:.getStages();
This works in CRM 2015 but not in CRM 2013.
You find further information here:
https://technet.microsoft.com/de-de/library/dn531164.aspx

Related

How to filter with "_links" properties params on API.v3 in openproject

I just learned to use "hypermedia rest API" on openproject
I want to use "filter" param with "_links" properties on API but not know-how
Example:
http:/<my_domain>/target/api/v3/projects/design/work_packages?filters=[{"updatedAt":{"operator":"<>d","values":["2017-06-10T22:00:00Z","2017-07-05T22:00:00Z"]}, "_links":{"type":{"title":{"operator":"=","values":["Box"]}}}]
==> My Question:
i not known use to "_links":{"type":{"title":{"operator":"=","values":["Box"]} params filter. Now, result is not filter for "_links"
And show me books name to learn API for to beginner
? (https://www.oreilly.com/library/view/restful-web-clients/9781491921890/ch04.html#callout_hal_clients_CO1-1) -> is this ok?
Help me, please!
Thanks!
Image for my api
What I understood you wanting to achieve is getting all work packages in the project "design" that have been updated last within a certain time interval and that are of the type "Box".
The filters in OpenProject do not differentiate between native properties (like updatedAt) and linked resources (like type) when it comes to the structure of the filters. The syntax is always
{"<name of the filter>": {"operator": "<operator>": "values": [<list of values>]}}
When it comes to the filter values however, there is a difference. For linked resource the client is expected to use the id whereas native value like an integer, string or date is required for the native properties.
For your request the above requires the client to issue the following query:
GET http://domain/target/api/v3/projects/design/work_packages?filters=[{"updatedAt":{"operator":"<>d","values":["2017-06-10T22:00:00Z","2017-07-05T22:00:00Z"]}}, {"type":{"operator":"=", "values":["10"]}}]
I took the id of 10 for the type "Box" out of the screenshot you provided.
To get the filter values of all available filter you can call
POST http://domain/target/api/v3/queries/form
with a body of
{"name":"default","_links":{"project":{"href":"/api/v3/projects/design"}}}
The response will list all available filters in the _embedded/schema/_embedded/filtersSchema array.

Neto API Limitations

I'm currently attempting to integrate with the Neto Ecommerce API. I've hit all sorts of limitations that I never see on other platforms and the latest is to do with custom fields.
The API Im using is the GetOrders API, and Im following the requirements to fetch transaction information, however custom fields appear to be missing. Hoping someone out there has made use of this API to extract custom fields and can advise on how to go about getting custom field information.
Any tips appreciated
var netoString = '{"Filter":{"OrderID":[""],"OutputSelector":["ID","ShippingOption","DeliveryInstruction","RelatedOrderID","cust1"]};
Is there an undocumented naming convention used to fetch custom fields or other pattern I can try to see if I can fetch the data?
I am not certain this will be the same for the API, but when using exports the correct format to access Custom Sales Order Fields is "customer_ref1".
To get a Custom Customer Fields is "usercustom1"
Note: For the Custom Customer Fields, the numbers do not match up correctly (I.E. usercustom1 doesn't match misc1 in the cpanel). The correct matches are:
misc1=usercustom1
misc2=usercustom4
misc3=usercustom5
misc4=usercustom6
misc5=usercustom7
misc6=usercustom11
misc7=usercustom12
misc8=usercustom13
misc9=usercustom14
misc10=usercustom15
misc11=usercustom16
misc12=usercustom17
misc13=usercustom18
misc14=usercustom19
misc15=usercustom20
misc16=usercustom21
misc17=usercustom22
misc18=usercustom23
misc19=usercustom24
misc20=usercustom25
misc21=usercustom10
misc22=usercustom26
misc23=usercustom27
misc24=usercustom28
misc25=usercustom29
misc26=usercustom30
misc27=usercustom31
misc28=usercustom32
misc29=usercustom33
misc30=usercustom34
misc31=usercustom35
misc32=usercustom36
misc33=usercustom37
misc34=usercustom38
misc35=usercustom39
misc36=usercustom40

Retrieving PDF report from BO4.1 Webservice

I am trying to migrate my web service client from BO 3.x to BO 4.1 Restful.
The existing implementation of BO 3.x uses BO java SDK to get CUID and doc properties to get the PDF report by using below inputs.
Report Path : path://InfoObjects/Root Folder/Application Name/Report
Name.rpt
Fill Parameter List : Parameter 1, Parameter 2, Parameter 3 etc to identify a report.
I have constructed my client code to get Logon token from RESTful web service. However I am not sure how to retrieve the PDF file now in BO 4.1.
Many of the samples I have seen uses sIDType and iDocID parameters along with Token value to retrieve the document by constructing a URL like below
http://server:port/BOE/OpenDocument/opendoc/openDocument.jsp?token=[LogonToken]&iDocID=[XXXX]&sIDType=CUID
My question : Is it must to have iDocID to retrieve document using URL pattern above or is it possible to construct a URL using report path / CUID and fill parameters ( without using iDocID) to retrieve pdf report from BO Web service.
Please assist me on this. Thanks
Note the &sIDType=CUID parameter in your sample URL -- that indicates that the page is expecting the value of iDocID to be a CUID. Without sIDType=CUID, it would expect the value to be an integer document ID.
That is, you only need the CUID, not the document ID. Also, CUID is unique, so there would be no value in specifying both CUID and path.
Incidentally, instead of specifying a CUID or ID, you can specify the document's path and name. However, this functionality is deprecated in BI4.1.
Prompt values can be supplied to openDocument using the lsS and lsM parameters (for single-select and multi-select prompts, respectively).
See the openDocument documentation here.

YouTrack rest api - Get fields metadata

I want to create issues with the youtrack rest api,
Currently I'm using:
PUT /rest/issue?{project}&{summary}&{description}&{attachments}&{permittedGroup}
but I want to set other fields (priority, type, subsystem...)
How do I get a list of available fields from the api? and the fields metadata(is mandatory, field type...)?
And after that, How do I set the value of these fields?
I found this in the docs:
https://confluence.jetbrains.com/display/YTD6/Apply+Command+to+an+Issue
but it looks too complex for setting a field.
Issue can be created with following method and fields set only https://confluence.jetbrains.com/display/YTD6/Create+New+Issue . So as you mentioned, it's
PUT /rest/issue?{project}&{summary}&{description}&{attachments}&{permittedGroup}
It's assumed, other fields can be updated within next call. ApplyCommand (https://confluence.jetbrains.com/display/YTD6/Apply+Command+to+an+Issue)method is pretty good example of such a method.
If you need to know all available fields in the projects, here is the method https://confluence.jetbrains.com/display/YTD6/GET+Project+Custom+Fields.
Meta can be called with the following https://confluence.jetbrains.com/display/YTD6/GET+Project+Custom+Field. As you can see, details are available on per field basis.

How to get sprint or iteration details of a project in rtc jazz using OSLC

Can any one help me to get the list of iterations and sprints in that and workitems in that sprint using oslc or REST call
This thread reports that querying iterations might be a bit tricky:
For the purpose of obtaining iteration for specific development line. Reporting Rest I/F may helps.
https://clm.example.com:9443/ccm/rpt/repository/foundation?fields=foundation/iteration[developmentLine/name='RTC V4.0.6 Development']/(id|name|developmentLine/name)
This yields some thing like:
<iteration> <developmentline> <name> <iteration>
<developmentline><name>RTC V4.0.6 Development</name></developmentline>
<id>Sprint 2</id>
<name>Sprint 2</name>
</iteration> </name> </developmentline> </iteration>
Unfortunately, iteration belongs to development line, so we have to query developmentLine using like:
https://clm.example.com:9443/ccm/rpt/repository/foundation?fields=foundation/developmentLine/(name|projectArea/name)
For the brief introduction to reportable RestAPI, refer to this web pages.
https://jazz.net/wiki/bin/view/Main/ReportsRESTAPI
Good feature of this reports API is that we can query by name, not uuid of objects.
There
I had also this problems solved by this way. Try it.
It returns list of Open Sprints.
http://jira.address/rest/greenhopper/1.0/sprint/picker
If you want to search for closed sprints in the future, you can use the following parameter in the above call:
http://jira.address/rest/greenhopper/1.0/sprint/picker?excludeCompleted=false